1

I'm trying to write a kernel test for a service in my custom module.
This service depends on certain configuration values that are installed by default when the module is enabled. Values are stored in /config/install/mymodule.settings.yml
If I try to get these configuration values in my test setUp() function, I get the correct value.
However, when the test is running, the same value is null when called from inside the service.
Any idea why?

1 Answer 1

2

Turned out to be a very silly mistake...
I instatiated the service before installing the config with $this->installConfig(['mymodule'])

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.