fix(deps): update dependency react-select to v4 (#2663)

* fix(deps): update dependency react-select to v4

* fix(tests): fix tests for react-select v4

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Łukasz Mierzwa <l.mierzwa@gmail.com>
This commit is contained in:
renovate[bot]
2021-01-25 18:37:28 +00:00
committed by GitHub
parent 2b660992ae
commit dc8d21a2cb
24 changed files with 325 additions and 121 deletions

View File

@@ -7,14 +7,13 @@ import toDiffableHtml from "diffable-html";
import { MockThemeContext } from "__fixtures__/Theme";
import { useFetchGetMock } from "__fixtures__/useFetchGet";
import { Settings } from "Stores/Settings";
import { ThemeContext } from "Components/Theme";
import { AlertGroupSortConfiguration } from "./AlertGroupSortConfiguration";
let settingsStore: Settings;
beforeEach(() => {
settingsStore = new Settings(null);
jest.spyOn(React, "useContext").mockImplementation(() => MockThemeContext);
});
afterEach(() => {
@@ -22,7 +21,10 @@ afterEach(() => {
});
const FakeConfiguration = () => {
return mount(<AlertGroupSortConfiguration settingsStore={settingsStore} />);
return mount(<AlertGroupSortConfiguration settingsStore={settingsStore} />, {
wrappingComponent: ThemeContext.Provider,
wrappingComponentProps: { value: MockThemeContext },
});
};
const ExpandSortLabelSuggestions = () => {