Created
February 10, 2019 02:27
-
-
Save thisismydesign/f5fae664c56c78372ced1bd6e8b86e59 to your computer and use it in GitHub Desktop.
Mocking per test case with Jest /1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe("<Component />", () => { | |
it("works", () => { | |
// ... | |
}): | |
describe("when something silly happens", () => { | |
beforeEach(() => { | |
jest.mock("MyOtherComponent", () => { | |
// ... | |
}) | |
}); | |
it("works differently", () => { | |
// ... | |
}): | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment