mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-01-21 16:30:25 +00:00
Fix unit test
This commit is contained in:
parent
a2556dad06
commit
905aa26f27
@ -69,7 +69,7 @@ jest.mock("Explorer/Controls/Dialog", () => ({
|
|||||||
useDialog: {
|
useDialog: {
|
||||||
getState: jest.fn(() => ({
|
getState: jest.fn(() => ({
|
||||||
showOkCancelModalDialog: (title: string, subText: string, okLabel: string, onOk: () => void) => onOk(),
|
showOkCancelModalDialog: (title: string, subText: string, okLabel: string, onOk: () => void) => onOk(),
|
||||||
showOkModalDialog: () => {},
|
showOkModalDialog: () => { },
|
||||||
})),
|
})),
|
||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
@ -92,7 +92,11 @@ async function waitForComponentToPaint<P = unknown>(wrapper: ReactWrapper<P> | S
|
|||||||
describe("Documents tab (noSql API)", () => {
|
describe("Documents tab (noSql API)", () => {
|
||||||
describe("buildQuery", () => {
|
describe("buildQuery", () => {
|
||||||
it("should generate the right select query for SQL API", () => {
|
it("should generate the right select query for SQL API", () => {
|
||||||
expect(buildQuery(false, "")).toContain("select");
|
expect(buildQuery(false, "", ['pk'], {
|
||||||
|
paths: ['pk'],
|
||||||
|
kind: 'Hash',
|
||||||
|
version: 2,
|
||||||
|
})).toContain("select");
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user