Skip to content

Commit

Permalink
add .default to mock
Browse files Browse the repository at this point in the history
  • Loading branch information
bubonicfred committed Jun 18, 2024
1 parent 9dbea88 commit cb5c411
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tests/unit/client/helpers/submitOnEnter.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,12 @@ import sinon from "sinon";
import esmock from "esmock";

const jQueryOnStub = sinon.stub();
// This might need .default; or the equivilent after?

const submitOnEnter = await esmock("../../../../client/helpers/submitOnEnter", {
"meteor/jquery": { $: () => sinon.stub().returns({ on: jQueryOnStub, }) },
}, {}, {
isModuleNotFoundError: false
});
}).default;

// skipcq: JS-0241
describe("submitOnEnter", function () {
Expand Down

0 comments on commit cb5c411

Please sign in to comment.