diff --git a/packages/expect/src/__tests__/toThrowMatchers.test.js b/packages/expect/src/__tests__/toThrowMatchers.test.js index 10fc0fb25a01..3c723369aecf 100644 --- a/packages/expect/src/__tests__/toThrowMatchers.test.js +++ b/packages/expect/src/__tests__/toThrowMatchers.test.js @@ -94,13 +94,13 @@ class customError extends Error { describe('regexp', () => { it('passes', () => { - expect(() => { + jestExpect(() => { throw new customError('apple'); })[toThrow](/apple/); - expect(() => { + jestExpect(() => { throw new customError('banana'); }).not[toThrow](/apple/); - expect(() => {}).not[toThrow](/apple/); + jestExpect(() => {}).not[toThrow](/apple/); }); test('did not throw at all', () => {