Closed iskey closed 1 year ago
@iskey can you add a test to validate please?
Thanks, let me take a look.
@iskey can you add a test to validate please?
ok, let me do some tests.
Better to do a mock test. Post two snapshots for contrast for now:
from
to
Better to do a mock test. Post two snapshots for contrast for now:
from
to
Sounds good!
If possible try avoiding a mock please, it is like not testing at all at the end. Using surefire you can force some env var so it is then easy to check it is used or not cases IMHO.
I think we don't need a mock for the test. We can directly test the ConfigService
and setting a system property to test.
Actually, I think for this kind of "simple" bug, we can just move forward without test.
If no objection, I will merge this PR.
Guess the regex should be extracted if config service is used at runtime instead of recompiled each time.
@rmannibucau good point, we can have the Pattern compile as static.
@jbonofre agree, no mock is needed, go for merge.
Agree, no mock here. Actually, it is hard to mock without extracting the getEnv
as another method.
Let me make the pattern static.
fix #10