Since we are using only composer as autoloader and we have all
dependencies on `require-dev` there is no need to check if third-party
libraries are present or not
- Move "tests/phpunit.xml" to "phpunit.xml.dist"
- Update documentation and contributing documents
- Update Travis settings
- Add "phpunit.xml" in the Git ignore list
Domain validator incorrectly stated that an ip would validate. See `Respect\Validation\Rules\DomainTest`
Added second valid Mac Address format demonstration using `-`. See `Respect\Validation\Rules\MacAddressTest`
The example in the "Informative Exceptions" section uses InvalidArgumentException, which is incorrect as that class does not have a getFullMessage() method. The class that defines getFullMessage() is AbstractNestedException, of which DomainException is a subclass, so I've replaced InvalidArgumentException with that to make the example accurate.
Also removes the unstable build badge, which is kind of redundant since
we will always respect the pattern of keeping the `master` branch stable
enough to be used.
Two Scrutinizer badges were added: code coverage and code quality.
Travis changed to report code coverage to Scrutinizer.
Skipping TLD check allows for local domains like "machine.dev",
but the default behavior of the rule still the same: it validates
TLDs, so domains will only be valid (by default) if the TLD is a
valid one.
The signature of rule (using the builder) changes from:
v::domain() // Still works, same behavior as before.
To:
v::domain(false) // Skips TLD check.
Fix#33.
The "Domain" rule now validates domains on "ASCII Compatible Encoding"
[ACE][1] for internationalized domain names (ICANN, 2003).
An excerpt from Wikipedia article:
> If given a label containing at least one non-ASCII character, ToASCII
> will apply the Nameprep algorithm, which converts the label to
> lowercase and performs other normalization, and will then translate the
> result to ASCII using [Punycode][16] before prepending the four-character
> string ["xn--"][17].
[1]: http://wikipedia.org/wiki/Internationalized_domain_name#ToASCII_and_ToUnicode
[16]: http://tools.ietf.org/html/rfc3492
[17]: http://www.atm.tut.fi/list-archive/ietf-announce/msg13572.html