Closed yeiniel closed 8 years ago
Another posibility is create an array of allowed messages and assert if the exception message is in the array
I'd also opt for @Maks3w idea of adding an array of allowed messages. Otherwise the tests will become messy and I'd much more like to have them as interpreter-agnostic as possible. And specifying a certain PHP-Version and the availability of a special constant feels a bit like user-agent sniffing.... ;)
ok, working on changes.
…n important detail is that PHP v5.6.11 also use the same message than PHP v7.x. Therefore this commit perform the comparison using PHP version 5.6.0 as break point. It will need further testing with other PHP version to determine .