You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I re-order test_Can_detect_missing_mandatory_environment_keys as the first test, it passes and now test_Can_parse_environment_file fails due to the same issue of an empty array
Any idea what I'm missing here?
The text was updated successfully, but these errors were encountered:
bilogic
changed the title
$this->dotenv->load() sometimes returns an empty array
Inconsistent result when calling $this->dotenv->load() multiple times from PHPUnit
Apr 26, 2024
Use createMutable while I would need to dig through the code to fully comprehend the inner workings, it seems that immutability in this instance returns configuration onces but not on "future" usage of "load()".
I'm not sure whether this is by design, hypothetically, you should be able to have multiple immutable configuration at whatever point you want that shouldn't change outside of a particular bound/context.
https://gist.github.com/bilogic/4114836067651905888abd542becee55
I have a set of flaky tests in the gist above. What I can't understand is:
test_Can_detect_missing_mandatory_environment_keys
fails and it is due to$this->dotenv->load();
returning an empty array here https://gist.github.com/bilogic/4114836067651905888abd542becee55#file-envchecker-php-L61test_Can_detect_missing_mandatory_environment_keys
as the first test, it passes and nowtest_Can_parse_environment_file
fails due to the same issue of an empty arrayAny idea what I'm missing here?
The text was updated successfully, but these errors were encountered: