SimpleRegex / SRL-PHP

Simple Regex Language
https://simple-regex.com
MIT License
1.8k stars 112 forks source link

Update .travis.yml #48

Closed andreybolonin closed 4 years ago

KarimGeiger commented 6 years ago

Thanks for your contribution, really appreciated!

Sadly, PHP seems to have changed the escaping for PHP 7.3, so the tests are now failing on that version. Could you maybe add a version check and a new assertion for tests/BuilderTest.php:174 and tests/LanguageInterpreterTest.php:55? I'm thinking of something like

if (PHP_VERSION_ID >= 70300) {
    // PHP 7.3 made changes to regex escaping
    $this->assertEquals('/[^a\$\#]/', $regex);
} else {
    $this->assertEquals('/[^a\$#]/', $regex);
}