auraphp / Aura.Filter

Validate and sanitize arrays and objects.
MIT License
159 stars 33 forks source link

Skip 2 email validation tests if the Intl extension is not loaded #105

Closed jakejohns closed 8 years ago

jakejohns commented 8 years ago

I'm not sure this is the best way to do this, but I think it makes more sense than having the tests fail if the extension is not loaded. This seemed slightly less hackish than using reflection to read the private dataName property to check the provider key, and less intrusive than making the test accept another arg for every test?

pmjones commented 8 years ago

Interesting. Maybe instead, have a new test method just for this test class, that tests IDNs if the intl extension is available? That way there's no checking the argument count, etc. (Hope that made sense. :-)

jakejohns commented 8 years ago

Ya I think that makes more sense. Better like this?

pmjones commented 8 years ago

@jakejohns Nice.

@harikt I think for this specific case, the extra method is reasonable, since we're making an "extra" check against an extension.

harikt commented 8 years ago

cool :) .