diff --git a/ui/src/Components/SilenceModal/SilenceMatch/LabelValueInput.test.js b/ui/src/Components/SilenceModal/SilenceMatch/LabelValueInput.test.js index 9b2c095b9..00a529816 100644 --- a/ui/src/Components/SilenceModal/SilenceMatch/LabelValueInput.test.js +++ b/ui/src/Components/SilenceModal/SilenceMatch/LabelValueInput.test.js @@ -14,6 +14,10 @@ import { LabelValueInput } from "./LabelValueInput"; let silenceFormStore; let matcher; +beforeAll(() => { + fetch.mockResponse(JSON.stringify([])); +}); + beforeEach(() => { silenceFormStore = new SilenceFormStore(); matcher = NewEmptyMatcher(); @@ -28,6 +32,10 @@ beforeEach(() => { ]; }); +afterEach(() => { + jest.restoreAllMocks(); +}); + const ShallowLabelValueInput = isValid => { return shallow(