ExtensionStrategy-NoProxy.spec.js (hoppscotch-2.2.1) | : | ExtensionStrategy-NoProxy.spec.js (hoppscotch-3.0.0) | ||
---|---|---|---|---|
skipping to change at line 125 | skipping to change at line 125 | |||
cancelRunningExtensionRequest() | cancelRunningExtensionRequest() | |||
expect(cancelFunc).toHaveBeenCalledTimes(1) | expect(cancelFunc).toHaveBeenCalledTimes(1) | |||
}) | }) | |||
test("does not cancel request if extension not installed", () => { | test("does not cancel request if extension not installed", () => { | |||
global.__POSTWOMAN_EXTENSION_HOOK__ = undefined | global.__POSTWOMAN_EXTENSION_HOOK__ = undefined | |||
cancelRunningExtensionRequest() | cancelRunningExtensionRequest() | |||
expect(cancelFunc).not.toHaveBeenCalled() | expect(cancelFunc).not.toHaveBeenCalled() | |||
}) | }) | |||
test("does not cancel request if extension installed but function not present" | ||||
, () => { | ||||
global.__POSTWOMAN_EXTENSION_HOOK__ = {} | ||||
cancelRunningExtensionRequest() | ||||
expect(cancelFunc).not.toHaveBeenCalled() | ||||
}) | ||||
}) | }) | |||
describe("extensionStrategy", () => { | describe("extensionStrategy", () => { | |||
const sendReqFunc = jest.fn() | const sendReqFunc = jest.fn() | |||
beforeEach(() => { | beforeEach(() => { | |||
sendReqFunc.mockClear() | sendReqFunc.mockClear() | |||
}) | }) | |||
describe("Non-Proxy Requests", () => { | describe("Non-Proxy Requests", () => { | |||
End of changes. 1 change blocks. | ||||
8 lines changed or deleted | 0 lines changed or added |