Use built-in alertmanager config if no fallback config is provided
What this PR does
Which issue(s) this PR fixes or relates to
Fixes #2772
Checklist
- [x] Tests updated
- [x] Documentation added
- [x]
CHANGELOG.mdupdated - the order of entries should be[CHANGE],[FEATURE],[ENHANCEMENT],[BUGFIX]
The CHANGELOG has just been cut to prepare for the next Mimir release. Please rebase main and eventually move the CHANGELOG entry added / updated in this PR to the top of the CHANGELOG document. Thanks!
There is also one in the integration folder, which is not failing correctly. I'm investigating it.
The thing was that the mock that we are using in the test was built manually and not using the constructor, thus no fallback config was computed. I fixed that here, and now everything works as expected. The tests were failing and I rewrote them to reflect those changes and check for the default config instead of a 412 after a deletion. For the frontend tests the expected behavior is a redirect instead of a 412 after deletion, as the fallback config is used.
Nice job, thanks!