Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not load default ini files in tests #16099

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

arnaud-lb
Copy link
Member

@arnaud-lb arnaud-lb commented Sep 28, 2024

make test concatenates the default ini files (from config-file-path and config-file-scan-dir) into a temporary tmp-php.ini, which is loaded in tests.

This leads to unexpected results, and sometimes to difficulties when trying to debug failing tests (although that's mostly because generated .sh scripts for failing tests try to load the tmp-php.ini file, which is removed by make test).

I think that we should not load any ini file by default in tests, to reduce the impact of the environment on the test suite. It is always possible to specify an ini file explicitly (make test TESTS="-c file.ini") or ini settings (make test TESTS="-d ...").

On Windows, nmake test doesn't load any ini file by default. When building with --enable-test-ini, a tmp-php.ini file is generated and loaded by nmake test, but it contains only directives for loading the shared extensions of the build.

@arnaud-lb arnaud-lb changed the title Do load default ini files in tests Do not load default ini files in tests Sep 28, 2024
@arnaud-lb arnaud-lb marked this pull request as ready for review September 28, 2024 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant