diff options
Diffstat (limited to 'src/tests')
| -rw-r--r-- | src/tests/php8/inexistent_conf_file.phpt | 14 | ||||
| -rw-r--r-- | src/tests/php8/inexistent_conf_file_list.phpt | 14 |
2 files changed, 28 insertions, 0 deletions
diff --git a/src/tests/php8/inexistent_conf_file.phpt b/src/tests/php8/inexistent_conf_file.phpt new file mode 100644 index 0000000..ac763aa --- /dev/null +++ b/src/tests/php8/inexistent_conf_file.phpt | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | --TEST-- | ||
| 2 | Test for unexistent configuration file, in php8 | ||
| 3 | --SKIPIF-- | ||
| 4 | <?php if (!extension_loaded("snuffleupagus")) print "skip"; ?> | ||
| 5 | <?php if (PHP_VERSION_ID < 80000) print "skip"; ?> | ||
| 6 | --INI-- | ||
| 7 | sp.configuration_file={PWD}/config/unexistent_configuration_file.ini | ||
| 8 | --FILE-- | ||
| 9 | <?php ?> | ||
| 10 | --EXPECTF-- | ||
| 11 | Fatal error: [snuffleupagus][0.0.0.0][config][log] Could not open configuration file %a/config/unexistent_configuration_file.ini : No such file or directory in Unknown on line 0 | ||
| 12 | |||
| 13 | Fatal error: [snuffleupagus][0.0.0.0][config][log] Invalid configuration file in Unknown on line 0 | ||
| 14 | Could not startup. | ||
diff --git a/src/tests/php8/inexistent_conf_file_list.phpt b/src/tests/php8/inexistent_conf_file_list.phpt new file mode 100644 index 0000000..2309fc6 --- /dev/null +++ b/src/tests/php8/inexistent_conf_file_list.phpt | |||
| @@ -0,0 +1,14 @@ | |||
| 1 | --TEST-- | ||
| 2 | Non-existent configuration file in a list in php8 | ||
| 3 | --SKIPIF-- | ||
| 4 | <?php if (!extension_loaded("snuffleupagus")) print "skip"; ?> | ||
| 5 | <?php if (PHP_VERSION_ID < 80000) print "skip"; ?> | ||
| 6 | --INI-- | ||
| 7 | sp.configuration_file={PWD}/../../../config/default.rules,{PWD}/non_existent_configuration_file | ||
| 8 | --FILE-- | ||
| 9 | <?php ?> | ||
| 10 | --EXPECTF-- | ||
| 11 | Fatal error: [snuffleupagus][0.0.0.0][config][log] Could not open configuration file %a/non_existent_configuration_file : No such file or directory in Unknown on line 0 | ||
| 12 | |||
| 13 | Fatal error: [snuffleupagus][0.0.0.0][config][log] Invalid configuration file in Unknown on line 0 | ||
| 14 | Could not startup. | ||
