mirror of
https://github.com/prymitive/karma
synced 2026-05-23 04:42:58 +00:00
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:
@@ -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 = () => {
|
||||
|
||||
Reference in New Issue
Block a user