diff --git a/__mocks__/monaco-editor.ts b/__mocks__/monaco-editor.ts index cbe02cb296..1623a6f00b 100644 --- a/__mocks__/monaco-editor.ts +++ b/__mocks__/monaco-editor.ts @@ -3,3 +3,12 @@ * Licensed under MIT License. See LICENSE in root directory for more information. */ export default {}; + +export const Uri = { + file: (path: string) => path, +}; + +export const editor = { + getModel: () => ({}), + create: () => ({}), +}; diff --git a/__mocks__/react-virtualized-auto-sizer.tsx b/__mocks__/react-virtualized-auto-sizer.tsx new file mode 100644 index 0000000000..ede5de41cb --- /dev/null +++ b/__mocks__/react-virtualized-auto-sizer.tsx @@ -0,0 +1,17 @@ +/** + * Copyright (c) OpenLens Authors. All rights reserved. + * Licensed under MIT License. See LICENSE in root directory for more information. + */ +import React from "react"; +import type { Size } from "react-virtualized-auto-sizer"; + +export default ({ children } : { children: (size: Size) => React.ReactNode }) => { + return ( +
+ {children({ + height: 420000, + width: 100, + })} +
+ ); +}; diff --git a/src/behaviours/cluster/__snapshots__/order-of-sidebar-items.test.tsx.snap b/src/behaviours/cluster/__snapshots__/order-of-sidebar-items.test.tsx.snap index a942d936d2..0b424f4ce2 100644 --- a/src/behaviours/cluster/__snapshots__/order-of-sidebar-items.test.tsx.snap +++ b/src/behaviours/cluster/__snapshots__/order-of-sidebar-items.test.tsx.snap @@ -472,6 +472,7 @@ exports[`cluster - order of sidebar items when rendered renders 1`] = ` >