fix(deps): update dependency jsdom to v22 #12006
This run and associated checks have been archived and are scheduled for deletion.
Learn more about checks retention
nodejs.yml
on: pull_request
prepare-yarn-cache-ubuntu
/
Prepare yarn cache for ubuntu-latest
1m 37s
prepare-yarn-cache-macos
/
Prepare yarn cache for macos-latest
1m 49s
prepare-yarn-cache-windows
/
Prepare yarn cache for windows-latest
2m 39s
Matrix: test-ubuntu / test-jasmine
TypeScript Compatibility
5m 59s
Typecheck Examples and Tests
4m 22s
Lint
3m 26s
Validate Yarn dependencies and constraints
23s
Node LTS on Ubuntu with leak detection
1m 18s
Matrix: test-coverage
Matrix: test-ubuntu / test
Matrix: test-macos / test-jasmine
Matrix: test-macos / test
Matrix: test-windows / test-jasmine
Matrix: test-windows / test
Annotations
88 errors
calls asynchronous handleTestEvent in testEnvironment:
e2e/__tests__/testEnvironmentCircusAsync.test.ts#L18
expect(received).toMatchInlineSnapshot(snapshot)
Snapshot name: `calls asynchronous handleTestEvent in testEnvironment 1`
- Snapshot - 44
+ Received + 1
Array [
- "setup",
- "warning: add_hook is a sync event",
- "warning: start_describe_definition is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_test is a sync event",
- "warning: add_test is a sync event",
- "warning: finish_describe_definition is a sync event",
- "add_hook",
- "start_describe_definition",
- "add_hook",
- "add_hook",
- "add_test",
- "add_test",
- "finish_describe_definition",
- "run_start",
- "run_describe_start",
- "run_describe_start",
- "test_start: passing test",
- "test_started: passing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: passing test",
- "test_fn_success: passing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: passing test",
- "test_start: failing test",
- "test_started: failing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: failing test",
- "test_fn_failure: failing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: failing test",
- "run_describe_finish",
- "run_describe_finish",
- "run_finish",
- "teardown",
+ "",
]
at Object.toMatchInlineSnapshot (e2e/__tests__/testEnvironmentCircusAsync.test.ts:18:17)
|
calls testEnvironment handleTestEvent:
e2e/__tests__/testEnvironmentCircus.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: false
Received: true
at Object.toBe (e2e/__tests__/testEnvironmentCircus.test.ts:15:25)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L16
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 1`
- Snapshot - 40
+ Received + 9
FAIL __tests__/dom.test.js
- ✕ use toBe compare two div
- ✕ compare span and div
-
- ● use toBe compare two div
-
- expect(received).toBe(expected) // Object.is equality
-
- If it should pass with deep equality, replace "toBe" with "toStrictEqual"
-
- Expected: <div />
- Received: serializes to the same string
-
- 12 | const div1 = document.createElement('div');
- 13 | const div2 = document.createElement('div');
- > 14 | expect(div1).toBe(div2);
+ ● Test suite failed to run
+
+ /home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 15 | });
- 16 |
- 17 | test('compare span and div', () => {
-
- at Object.toBe (__tests__/dom.test.js:14:16)
-
- ● compare span and div
-
- expect(received).toBe(expected) // Object.is equality
-
- - Expected - 1
- + Received + 1
-
- - <span />
- + <div />
-
- 16 |
- 17 | test('compare span and div', () => {
- > 18 | expect(document.createElement('div')).toBe(document.createElement('span'));
- | ^
- 19 | });
- 20 |
-
- at Object.toBe (__tests__/dom.test.js:18:41)
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:16:16)
at runMicrotasks (<anonymous>)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L17
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 2`
- Snapshot - 1
+ Received + 1
Test Suites: 1 failed, 1 total
- Tests: 2 failed, 2 total
+ Tests: 0 total
Snapshots: 0 total
Time: <<REPLACED>>
Ran all test suites.
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:17:19)
at runMicrotasks (<anonymous>)
|
test-ubuntu / Node v14.x on ubuntu-latest (3/4)
Process completed with exit code 1.
|
async jasmine › async test fails:
e2e/__tests__/jasmineAsync.test.ts#L173
expect(received).toEqual(expected) // deep equality
Expected: StringContaining "Received:"
Received: " ● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
"
at Object.toEqual (e2e/__tests__/jasmineAsync.test.ts:173:48)
|
the jsdom console is the same as the test console:
e2e/__tests__/console.test.ts#L90
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/console.test.ts:90:20)
|
Environment override › uses jsdom when specified:
e2e/__tests__/env.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:15:29)
|
Environment equivalent › uses jsdom:
e2e/__tests__/env.test.ts#L40
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:40:29)
|
check is not leaking memory:
e2e/__tests__/jestEnvironmentJsdom.test.ts#L26
expect(received).toMatch(expected)
Expected pattern: /PASS\s__tests__\/a.test.js/
Received string: "FAIL __tests__/b.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
FAIL __tests__/a.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 2 failed, 2 total
Tests: 0 total
Snapshots: 0 total
Time: 0.96 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/jestEnvironmentJsdom.test.ts:26:18)
|
browser resolver works:
e2e/__tests__/browserResolve.ts#L18
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/browserResolve.ts:18:20)
|
test-ubuntu / Node v14.x on ubuntu-latest (4/4)
Process completed with exit code 1.
|
successfully runs the tests with external babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L79
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.689 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:79:28)
at runMicrotasks (<anonymous>)
|
successfully runs the tests with inline babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L128
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.517 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:128:28)
at runMicrotasks (<anonymous>)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimersLegacy.test.ts#L35
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.957 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimersLegacy.test.ts:35:27)
at runMicrotasks (<anonymous>)
|
works with jsdom testEnvironmentOptions config JSON:
e2e/__tests__/config.test.ts#L65
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/config.test.ts:65:27)
at runMicrotasks (<anonymous>)
|
triggers setup/teardown hooks:
e2e/__tests__/testEnvironmentAsync.test.ts#L29
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/testEnvironmentAsync.test.ts:29:27)
at runMicrotasks (<anonymous>)
|
Wrong globals for environment › print useful error for unref:
e2e/__tests__/wrongEnv.test.ts#L14
expect(received).toMatchSnapshot()
Snapshot name: `Wrong globals for environment print useful error for unref 1`
- Snapshot - 18
+ Received + 9
FAIL __tests__/jsdom.js
- ✕ use unref
-
- ● use unref
-
- The error below may be caused by using the wrong test environment, see https://jestjs.io/docs/configuration#testenvironment-string.
- Consider using the "node" test environment.
-
- TypeError: setTimeout(...).unref is not a function
-
- 11 |
- 12 | test('use unref', () => {
- > 13 | setTimeout(() => {}, 0).unref();
+ ● Test suite failed to run
+
+ /home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 14 |
- 15 | expect(1).toBe(1);
- 16 | });
-
- at Object.unref (__tests__/jsdom.js:13:27)
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at toMatchSnapshot (e2e/__tests__/wrongEnv.test.ts:14:46)
at Object.assertFailuresAndSnapshot (e2e/__tests__/wrongEnv.test.ts:31:5)
at runMicrotasks (<anonymous>)
|
test-ubuntu / Node v14.x on ubuntu-latest (2/4)
Process completed with exit code 1.
|
print correct error message with nested test definitions outside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L29
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions outside describe 1`
- Snapshot - 15
+ Received + 9
FAIL __tests__/nestedTestOutsideDescribe.js
- ✕ outer test
-
- ● outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 13 | expect(getTruthy()).toBeTruthy();
- 14 |
- > 15 | test('inner test', () => {
- | ^
- 16 | expect(getTruthy()).toBe('This test should not have run');
- 17 | });
- 18 | });
-
- at Object.test (__tests__/nestedTestOutsideDescribe.js:15:3)
+ ● Test suite failed to run
+
+ /home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:29:44)
|
print correct error message with nested test definitions inside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L39
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions inside describe 1`
- Snapshot - 16
+ Received + 9
FAIL __tests__/nestedTestWithinDescribe.js
- in describe
- ✕ outer test
-
- ● in describe › outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 14 | expect(getTruthy()).toBeTruthy();
- 15 |
- > 16 | test('inner test', () => {
- | ^
- 17 | expect(getTruthy()).toBeTruthy();
- 18 | });
- 19 | });
-
- at Object.test (__tests__/nestedTestWithinDescribe.js:16:5)
+ ● Test suite failed to run
+
+ /home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:39:44)
|
print correct message when nesting describe inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L49
expect(received).toContain(expected) // indexOf
Expected substring: "Cannot nest a describe inside a test. Describe block \"inner describe\" cannot run because it is nested within \"test\"."
Received string: "FAIL __tests__/nestedDescribeInTest.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.408 s
Ran all test suites matching /nestedDescribeInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:49:27)
|
print correct message when nesting a hook inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L62
expect(received).toContain(expected) // indexOf
Expected substring: "Hooks cannot be defined inside tests. Hook of type \"beforeEach\" is nested within \"test\"."
Received string: "FAIL __tests__/nestedHookInTest.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.405 s
Ran all test suites matching /nestedHookInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:62:27)
|
useFakeTimers › allows to pass doNotFake option:
e2e/__tests__/fakeTimers.test.ts#L30
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/fakeTimers.test.ts:30:29)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimers.test.ts#L57
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
/home/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.972 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimers.test.ts:57:27)
|
respects testEnvironment docblock:
e2e/__tests__/testEnvironment.test.ts#L25
expect(received).toBe(expected) // Object.is equality
Expected: true
Received: false
at Object.toBe (e2e/__tests__/testEnvironment.test.ts:25:26)
|
resolves package exports correctly with custom resolver:
e2e/__tests__/resolveConditions.test.ts#L20
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/resolveConditions.test.ts:20:24)
|
works with nested event loops:
e2e/__tests__/nestedEventLoop.test.ts#L12
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/nestedEventLoop.test.ts:12:27)
|
test-ubuntu / Node v14.x on ubuntu-latest (1/4)
Process completed with exit code 1.
|
successfully runs the tests with external babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L79
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (D:/a/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 2.085 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:79:28)
|
successfully runs the tests with inline babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L128
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (D:/a/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.567 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:128:28)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimersLegacy.test.ts#L35
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.003 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimersLegacy.test.ts:35:27)
|
works with jsdom testEnvironmentOptions config JSON:
e2e/__tests__/config.test.ts#L65
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/config.test.ts:65:27)
|
triggers setup/teardown hooks:
e2e/__tests__/testEnvironmentAsync.test.ts#L29
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/testEnvironmentAsync.test.ts:29:27)
|
Wrong globals for environment › print useful error for unref:
e2e/__tests__/wrongEnv.test.ts#L14
expect(received).toMatchSnapshot()
Snapshot name: `Wrong globals for environment print useful error for unref 1`
- Snapshot - 18
+ Received + 9
"FAIL __tests__/jsdom.js
- ✕ use unref
-
- ● use unref
-
- The error below may be caused by using the wrong test environment, see https://jestjs.io/docs/configuration#testenvironment-string.
- Consider using the "node" test environment.
-
- TypeError: setTimeout(...).unref is not a function
-
- 11 |
- 12 | test('use unref', () => {
- > 13 | setTimeout(() => {}, 0).unref();
+ ● Test suite failed to run
+
+ D:\a\jest\jest\node_modules\jsdom\lib\jsdom\living\nodes\HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 14 |
- 15 | expect(1).toBe(1);
- 16 | });
-
- at Object.unref (__tests__/jsdom.js:13:27)"
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)"
at toMatchSnapshot (e2e/__tests__/wrongEnv.test.ts:14:46)
at Object.assertFailuresAndSnapshot (e2e/__tests__/wrongEnv.test.ts:31:5)
|
test-windows / Node v14.x on windows-latest (2/4)
Process completed with exit code 1.
|
print correct error message with nested test definitions outside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L29
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions outside describe 1`
- Snapshot - 15
+ Received + 9
"FAIL __tests__/nestedTestOutsideDescribe.js
- ✕ outer test
-
- ● outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 13 | expect(getTruthy()).toBeTruthy();
+ ● Test suite failed to run
+
+ D:\a\jest\jest\node_modules\jsdom\lib\jsdom\living\nodes\HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- 14 |
- > 15 | test('inner test', () => {
- | ^
- 16 | expect(getTruthy()).toBe('This test should not have run');
- 17 | });
- 18 | });
-
- at Object.test (__tests__/nestedTestOutsideDescribe.js:15:3)"
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)"
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:29:44)
|
print correct error message with nested test definitions inside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L39
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions inside describe 1`
- Snapshot - 16
+ Received + 9
"FAIL __tests__/nestedTestWithinDescribe.js
- in describe
- ✕ outer test
-
- ● in describe › outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 14 | expect(getTruthy()).toBeTruthy();
- 15 |
- > 16 | test('inner test', () => {
- | ^
+ ● Test suite failed to run
+
+ D:\a\jest\jest\node_modules\jsdom\lib\jsdom\living\nodes\HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
+ ^^^
+
- 17 | expect(getTruthy()).toBeTruthy();
- 18 | });
- 19 | });
-
- at Object.test (__tests__/nestedTestWithinDescribe.js:16:5)"
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)"
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:39:44)
|
print correct message when nesting describe inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L49
expect(received).toContain(expected) // indexOf
Expected substring: "Cannot nest a describe inside a test. Describe block \"inner describe\" cannot run because it is nested within \"test\"."
Received string: "FAIL __tests__/nestedDescribeInTest.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.767 s
Ran all test suites matching /nestedDescribeInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:49:27)
|
print correct message when nesting a hook inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L62
expect(received).toContain(expected) // indexOf
Expected substring: "Hooks cannot be defined inside tests. Hook of type \"beforeEach\" is nested within \"test\"."
Received string: "FAIL __tests__/nestedHookInTest.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 0.751 s
Ran all test suites matching /nestedHookInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:62:27)
|
useFakeTimers › allows to pass doNotFake option:
e2e/__tests__/fakeTimers.test.ts#L30
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/fakeTimers.test.ts:30:29)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimers.test.ts#L57
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.392 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimers.test.ts:57:27)
|
respects testEnvironment docblock:
e2e/__tests__/testEnvironment.test.ts#L25
expect(received).toBe(expected) // Object.is equality
Expected: true
Received: false
at Object.toBe (e2e/__tests__/testEnvironment.test.ts:25:26)
|
resolves package exports correctly with custom resolver:
e2e/__tests__/resolveConditions.test.ts#L20
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/resolveConditions.test.ts:20:24)
|
works with nested event loops:
e2e/__tests__/nestedEventLoop.test.ts#L12
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/nestedEventLoop.test.ts:12:27)
|
test-windows / Node v14.x on windows-latest (1/4)
Process completed with exit code 1.
|
async jasmine › async test fails:
e2e/__tests__/jasmineAsync.test.ts#L173
expect(received).toEqual(expected) // deep equality
Expected: StringContaining "Received:"
Received: " ● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
"
at Object.toEqual (e2e/__tests__/jasmineAsync.test.ts:173:48)
|
the jsdom console is the same as the test console:
e2e/__tests__/console.test.ts#L90
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/console.test.ts:90:20)
|
Environment override › uses jsdom when specified:
e2e/__tests__/env.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:15:29)
|
Environment equivalent › uses jsdom:
e2e/__tests__/env.test.ts#L40
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:40:29)
|
check is not leaking memory:
e2e/__tests__/jestEnvironmentJsdom.test.ts#L26
expect(received).toMatch(expected)
Expected pattern: /PASS\s__tests__\/a.test.js/
Received string: "FAIL __tests__/b.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (D:/a/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
FAIL __tests__/a.test.js
● Test suite failed to run·
D:\\a\\jest\\jest\\node_modules\\jsdom\\lib\\jsdom\\living\\nodes\\HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (D:/a/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 2 failed, 2 total
Tests: 0 total
Snapshots: 0 total
Time: 1.141 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/jestEnvironmentJsdom.test.ts:26:18)
|
browser resolver works:
e2e/__tests__/browserResolve.ts#L18
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/browserResolve.ts:18:20)
|
test-windows / Node v14.x on windows-latest (4/4)
Process completed with exit code 1.
|
calls asynchronous handleTestEvent in testEnvironment:
e2e/__tests__/testEnvironmentCircusAsync.test.ts#L18
expect(received).toMatchInlineSnapshot(snapshot)
Snapshot name: `calls asynchronous handleTestEvent in testEnvironment 1`
- Snapshot - 44
+ Received + 1
Array [
- "setup",
- "warning: add_hook is a sync event",
- "warning: start_describe_definition is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_test is a sync event",
- "warning: add_test is a sync event",
- "warning: finish_describe_definition is a sync event",
- "add_hook",
- "start_describe_definition",
- "add_hook",
- "add_hook",
- "add_test",
- "add_test",
- "finish_describe_definition",
- "run_start",
- "run_describe_start",
- "run_describe_start",
- "test_start: passing test",
- "test_started: passing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: passing test",
- "test_fn_success: passing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: passing test",
- "test_start: failing test",
- "test_started: failing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: failing test",
- "test_fn_failure: failing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: failing test",
- "run_describe_finish",
- "run_describe_finish",
- "run_finish",
- "teardown",
+ "",
]
at Object.toMatchInlineSnapshot (e2e/__tests__/testEnvironmentCircusAsync.test.ts:18:17)
at runMicrotasks (<anonymous>)
|
calls testEnvironment handleTestEvent:
e2e/__tests__/testEnvironmentCircus.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: false
Received: true
at Object.toBe (e2e/__tests__/testEnvironmentCircus.test.ts:15:25)
at runMicrotasks (<anonymous>)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L16
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 1`
- Snapshot - 40
+ Received + 9
"FAIL __tests__/dom.test.js
- ✕ use toBe compare two div
- ✕ compare span and div
-
- ● use toBe compare two div
-
- expect(received).toBe(expected) // Object.is equality
-
- If it should pass with deep equality, replace "toBe" with "toStrictEqual"
-
- Expected: <div />
- Received: serializes to the same string
-
- 12 | const div1 = document.createElement('div');
- 13 | const div2 = document.createElement('div');
- > 14 | expect(div1).toBe(div2);
+ ● Test suite failed to run
+
+ D:\a\jest\jest\node_modules\jsdom\lib\jsdom\living\nodes\HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 15 | });
- 16 |
- 17 | test('compare span and div', () => {
-
- at Object.toBe (__tests__/dom.test.js:14:16)
-
- ● compare span and div
-
- expect(received).toBe(expected) // Object.is equality
-
- - Expected - 1
- + Received + 1
-
- - <span />
- + <div />
-
- 16 |
- 17 | test('compare span and div', () => {
- > 18 | expect(document.createElement('div')).toBe(document.createElement('span'));
- | ^
- 19 | });
- 20 |
-
- at Object.toBe (__tests__/dom.test.js:18:41)"
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)"
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:16:16)
at runMicrotasks (<anonymous>)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L17
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 2`
- Snapshot - 1
+ Received + 1
Test Suites: 1 failed, 1 total
- Tests: 2 failed, 2 total
+ Tests: 0 total
Snapshots: 0 total
Time: <<REPLACED>>
Ran all test suites.
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:17:19)
at runMicrotasks (<anonymous>)
|
test-windows / Node v14.x on windows-latest (3/4)
Process completed with exit code 1.
|
print correct error message with nested test definitions outside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L29
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions outside describe 1`
- Snapshot - 15
+ Received + 9
FAIL __tests__/nestedTestOutsideDescribe.js
- ✕ outer test
-
- ● outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 13 | expect(getTruthy()).toBeTruthy();
+ ● Test suite failed to run
+
+ /Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- 14 |
- > 15 | test('inner test', () => {
- | ^
- 16 | expect(getTruthy()).toBe('This test should not have run');
- 17 | });
- 18 | });
-
- at Object.test (__tests__/nestedTestOutsideDescribe.js:15:3)
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:29:44)
|
print correct error message with nested test definitions inside describe:
e2e/__tests__/nestedTestDefinitions.test.ts#L39
expect(received).toMatchSnapshot()
Snapshot name: `print correct error message with nested test definitions inside describe 1`
- Snapshot - 16
+ Received + 9
FAIL __tests__/nestedTestWithinDescribe.js
- in describe
- ✕ outer test
-
- ● in describe › outer test
-
- Tests cannot be nested. Test "inner test" cannot run because it is nested within "outer test".
-
- 14 | expect(getTruthy()).toBeTruthy();
- 15 |
- > 16 | test('inner test', () => {
- | ^
- 17 | expect(getTruthy()).toBeTruthy();
- 18 | });
- 19 | });
-
- at Object.test (__tests__/nestedTestWithinDescribe.js:16:5)
+ ● Test suite failed to run
+
+ /Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/nestedTestDefinitions.test.ts:39:44)
|
print correct message when nesting describe inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L49
expect(received).toContain(expected) // indexOf
Expected substring: "Cannot nest a describe inside a test. Describe block \"inner describe\" cannot run because it is nested within \"test\"."
Received string: "FAIL __tests__/nestedDescribeInTest.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.003 s
Ran all test suites matching /nestedDescribeInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:49:27)
|
print correct message when nesting a hook inside it:
e2e/__tests__/nestedTestDefinitions.test.ts#L62
expect(received).toContain(expected) // indexOf
Expected substring: "Hooks cannot be defined inside tests. Hook of type \"beforeEach\" is nested within \"test\"."
Received string: "FAIL __tests__/nestedHookInTest.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.021 s
Ran all test suites matching /nestedHookInTest/i."
at Object.toContain (e2e/__tests__/nestedTestDefinitions.test.ts:62:27)
|
respects testEnvironment docblock:
e2e/__tests__/testEnvironment.test.ts#L25
expect(received).toBe(expected) // Object.is equality
Expected: true
Received: false
at Object.toBe (e2e/__tests__/testEnvironment.test.ts:25:26)
|
useFakeTimers › allows to pass doNotFake option:
e2e/__tests__/fakeTimers.test.ts#L30
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/fakeTimers.test.ts:30:29)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimers.test.ts#L57
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.994 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimers.test.ts:57:27)
|
resolves package exports correctly with custom resolver:
e2e/__tests__/resolveConditions.test.ts#L20
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/resolveConditions.test.ts:20:24)
|
works with nested event loops:
e2e/__tests__/nestedEventLoop.test.ts#L12
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/nestedEventLoop.test.ts:12:27)
|
test-macos / Node v14.x on macos-latest (1/4)
Process completed with exit code 1.
|
successfully runs the tests with external babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L79
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../../../../../Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 3.634 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:79:28)
|
successfully runs the tests with inline babel config:
e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts#L128
expect(received).toContain(expected) // indexOf
Expected substring: "1 snapshot failed from 1 test suite."
Received string: "FAIL __tests__/MismatchingSnapshot.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../../../../../Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 4.165 s
Ran all test suites."
at Object.toContain (e2e/__tests__/toMatchInlineSnapshotWithJSX.test.ts:128:28)
|
requestAnimationFrame › fakes requestAnimationFrame:
e2e/__tests__/fakeTimersLegacy.test.ts#L35
expect(received).toMatch(expected)
Expected substring: "requestAnimationFrame test"
Received string: "FAIL __tests__/requestAnimationFrame.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 1 failed, 1 total
Tests: 0 total
Snapshots: 0 total
Time: 1.798 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/fakeTimersLegacy.test.ts:35:27)
|
works with jsdom testEnvironmentOptions config JSON:
e2e/__tests__/config.test.ts#L65
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/config.test.ts:65:27)
|
triggers setup/teardown hooks:
e2e/__tests__/testEnvironmentAsync.test.ts#L29
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/testEnvironmentAsync.test.ts:29:27)
at runMicrotasks (<anonymous>)
|
Wrong globals for environment › print useful error for unref:
e2e/__tests__/wrongEnv.test.ts#L14
expect(received).toMatchSnapshot()
Snapshot name: `Wrong globals for environment print useful error for unref 1`
- Snapshot - 18
+ Received + 9
FAIL __tests__/jsdom.js
- ✕ use unref
-
- ● use unref
-
- The error below may be caused by using the wrong test environment, see https://jestjs.io/docs/configuration#testenvironment-string.
- Consider using the "node" test environment.
-
- TypeError: setTimeout(...).unref is not a function
-
- 11 |
- 12 | test('use unref', () => {
- > 13 | setTimeout(() => {}, 0).unref();
+ ● Test suite failed to run
+
+ /Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 14 |
- 15 | expect(1).toBe(1);
- 16 | });
-
- at Object.unref (__tests__/jsdom.js:13:27)
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at toMatchSnapshot (e2e/__tests__/wrongEnv.test.ts:14:46)
at Object.assertFailuresAndSnapshot (e2e/__tests__/wrongEnv.test.ts:31:5)
|
test-macos / Node v14.x on macos-latest (2/4)
Process completed with exit code 1.
|
async jasmine › async test fails:
e2e/__tests__/jasmineAsync.test.ts#L173
expect(received).toEqual(expected) // deep equality
Expected: StringContaining "Received:"
Received: " ● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
"
at Object.toEqual (e2e/__tests__/jasmineAsync.test.ts:173:48)
|
the jsdom console is the same as the test console:
e2e/__tests__/console.test.ts#L90
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/console.test.ts:90:20)
|
Environment override › uses jsdom when specified:
e2e/__tests__/env.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:15:29)
|
Environment equivalent › uses jsdom:
e2e/__tests__/env.test.ts#L40
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/env.test.ts:40:29)
|
check is not leaking memory:
e2e/__tests__/jestEnvironmentJsdom.test.ts#L26
expect(received).toMatch(expected)
Expected pattern: /PASS\s__tests__\/a.test.js/
Received string: "FAIL __tests__/b.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../../../../../Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
FAIL __tests__/a.test.js
● Test suite failed to run·
/Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
this[filesSymbol] ||= FileList.createImpl(this._globalObject);
^^^·
SyntaxError: Unexpected token '||='·
at Object.<anonymous> (../../../../../../../Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)·
Test Suites: 2 failed, 2 total
Tests: 0 total
Snapshots: 0 total
Time: 2.061 s
Ran all test suites."
at Object.toMatch (e2e/__tests__/jestEnvironmentJsdom.test.ts:26:18)
|
browser resolver works:
e2e/__tests__/browserResolve.ts#L18
expect(received).toBe(expected) // Object.is equality
Expected: 0
Received: 1
at Object.toBe (e2e/__tests__/browserResolve.ts:18:20)
|
test-macos / Node v14.x on macos-latest (4/4)
Process completed with exit code 1.
|
calls asynchronous handleTestEvent in testEnvironment:
e2e/__tests__/testEnvironmentCircusAsync.test.ts#L18
expect(received).toMatchInlineSnapshot(snapshot)
Snapshot name: `calls asynchronous handleTestEvent in testEnvironment 1`
- Snapshot - 44
+ Received + 1
Array [
- "setup",
- "warning: add_hook is a sync event",
- "warning: start_describe_definition is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_hook is a sync event",
- "warning: add_test is a sync event",
- "warning: add_test is a sync event",
- "warning: finish_describe_definition is a sync event",
- "add_hook",
- "start_describe_definition",
- "add_hook",
- "add_hook",
- "add_test",
- "add_test",
- "finish_describe_definition",
- "run_start",
- "run_describe_start",
- "run_describe_start",
- "test_start: passing test",
- "test_started: passing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: passing test",
- "test_fn_success: passing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: passing test",
- "test_start: failing test",
- "test_started: failing test",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "hook_start: beforeEach",
- "hook_success: beforeEach",
- "test_fn_start: failing test",
- "test_fn_failure: failing test",
- "hook_start: afterEach",
- "hook_failure: afterEach",
- "test_done: failing test",
- "run_describe_finish",
- "run_describe_finish",
- "run_finish",
- "teardown",
+ "",
]
at Object.toMatchInlineSnapshot (e2e/__tests__/testEnvironmentCircusAsync.test.ts:18:17)
|
calls testEnvironment handleTestEvent:
e2e/__tests__/testEnvironmentCircus.test.ts#L15
expect(received).toBe(expected) // Object.is equality
Expected: false
Received: true
at Object.toBe (e2e/__tests__/testEnvironmentCircus.test.ts:15:25)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L16
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 1`
- Snapshot - 40
+ Received + 9
FAIL __tests__/dom.test.js
- ✕ use toBe compare two div
- ✕ compare span and div
-
- ● use toBe compare two div
-
- expect(received).toBe(expected) // Object.is equality
-
- If it should pass with deep equality, replace "toBe" with "toStrictEqual"
-
- Expected: <div />
- Received: serializes to the same string
-
- 12 | const div1 = document.createElement('div');
- 13 | const div2 = document.createElement('div');
- > 14 | expect(div1).toBe(div2);
+ ● Test suite failed to run
+
+ /Users/runner/work/jest/jest/node_modules/jsdom/lib/jsdom/living/nodes/HTMLInputElement-impl.js:583
+ this[filesSymbol] ||= FileList.createImpl(this._globalObject);
- | ^
- 15 | });
- 16 |
- 17 | test('compare span and div', () => {
-
- at Object.toBe (__tests__/dom.test.js:14:16)
-
- ● compare span and div
-
- expect(received).toBe(expected) // Object.is equality
-
- - Expected - 1
- + Received + 1
-
- - <span />
- + <div />
-
- 16 |
- 17 | test('compare span and div', () => {
- > 18 | expect(document.createElement('div')).toBe(document.createElement('span'));
- | ^
- 19 | });
- 20 |
-
- at Object.toBe (__tests__/dom.test.js:18:41)
+ ^^^
+
+ SyntaxError: Unexpected token '||='
+
+ at Object.<anonymous> (../../node_modules/jsdom/lib/jsdom/living/generated/HTMLInputElement.js:1875:14)
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:16:16)
at runMicrotasks (<anonymous>)
|
should work without error:
e2e/__tests__/domDiffing.test.ts#L17
expect(received).toMatchSnapshot()
Snapshot name: `should work without error 2`
- Snapshot - 1
+ Received + 1
Test Suites: 1 failed, 1 total
- Tests: 2 failed, 2 total
+ Tests: 0 total
Snapshots: 0 total
Time: <<REPLACED>>
Ran all test suites.
at Object.toMatchSnapshot (e2e/__tests__/domDiffing.test.ts:17:19)
at runMicrotasks (<anonymous>)
|
test-macos / Node v14.x on macos-latest (3/4)
Process completed with exit code 1.
|
test-macos / Node v19.x on macos-latest (4/4)
Unexpected HTTP response: 500
|