diff --git a/package.json b/package.json index 29c8291..907b10b 100644 --- a/package.json +++ b/package.json @@ -23,11 +23,13 @@ }, "homepage": "https://github.com/MoLow/reporters#readme", "devDependencies": { - "@matteo.collina/snap": "^0.3.0", "c8": "^7.13.0", "eslint": "^7.32.0 || ^8.2.0", "eslint-config-airbnb-base": "^15.0.0", - "eslint-plugin-import": "^2.25.2" + "eslint-plugin-import": "^2.25.2", + "find-up": "^7.0.0", + "pretty-format": "^29.7.0", + "slash": "^5.1.0" }, "packageManager": "yarn@1.22.22+sha512.a6b2f7906b721bba3d67d4aff083df04dad64c399707841b7acf00f6b133b7ac24255f2652fa22ae3534329dc6180534e98d17432037ff6fd140556e2bb3137e" } diff --git a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json deleted file mode 100644 index 06976e1..0000000 --- a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": ".\n", - "exitCode": 0 -} \ No newline at end of file diff --git a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap new file mode 100644 index 0000000..1e8c5fa --- /dev/null +++ b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap @@ -0,0 +1,6 @@ +Object { + "exitCode": 0, + "stderr": "", + "stdout": ". +", +} \ No newline at end of file diff --git a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json deleted file mode 100644 index 57164ff..0000000 --- a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "node:internal/test_runner/harness:*\n throw err;\n ^\n\nError: Bail\n *\n at bail.next ()\n *\n *\n *\n *\n *\n *\n *\n *\nEmitted 'error' event on Duplex instance at:\n *\n *\n *\n\nNode.js *\n", - "stdout": "X\n\u001b[31m✖ Bailing on failed test: fail\u001b[0m\n", - "exitCode": 7 -} \ No newline at end of file diff --git a/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap new file mode 100644 index 0000000..44c7ec1 --- /dev/null +++ b/packages/bail/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap @@ -0,0 +1,28 @@ +Object { + "exitCode": 7, + "stderr": "node:internal/test_runner/harness:* + throw err; + ^ + +Error: Bail + * + at bail.next () + * + * + * + * + * + * + * + * +Emitted 'error' event on Duplex instance at: + * + * + * + +Node.js * +", + "stdout": "X +✖ Bailing on failed test: fail +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json deleted file mode 100644 index ea284bd..0000000 --- a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::starting to run fails\n::error title=fails,file=tests/example.js,line=9,col=11::Error [ERR_TEST_FAILURE]: this is an error%0A at async Promise.all (index 0) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:584:18)%0A at Test.postRun (node:internal/test_runner/test:983:19)%0A at Test.run (node:internal/test_runner/test:926:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:1268:7)%0A at async startSubtestAfterBootstrap (node:internal/test_runner/harness:280:3)%0A}\n::debug::starting to run is a diagnostic\n::debug::completed running is a diagnostic\n::notice file=tests/example.js,line=11,col=3::this is a diagnostic\n::debug::starting to run should fail\n::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:584:18)%0A at Test.postRun (node:internal/test_runner/test:983:19)%0A at Test.run (node:internal/test_runner/test:926:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:584:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A}\n::debug::starting to run more tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::completed running more tests\n::debug::starting to run is skipped\n::debug::completed running is skipped\n::debug::starting to run is a todo\n::debug::completed running is a todo\n::debug::starting to run top level diagnostic\n::debug::completed running top level diagnostic\n::notice file=tests/example.js,line=21,col=1::top level diagnostic\n::group::Test results (4 passed, 2 failed)\n::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap new file mode 100644 index 0000000..c373480 --- /dev/null +++ b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap @@ -0,0 +1,29 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::starting to run fails +::error title=fails,file=tests/example.js,line=9,col=11::Error [ERR_TEST_FAILURE]: this is an error%0A at async Promise.all (index 0) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:584:18)%0A at Test.postRun (node:internal/test_runner/test:983:19)%0A at Test.run (node:internal/test_runner/test:926:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:1268:7)%0A at async startSubtestAfterBootstrap (node:internal/test_runner/harness:280:3)%0A} +::debug::starting to run is a diagnostic +::debug::completed running is a diagnostic +::notice file=tests/example.js,line=11,col=3::this is a diagnostic +::debug::starting to run should fail +::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:584:18)%0A at Test.postRun (node:internal/test_runner/test:983:19)%0A at Test.run (node:internal/test_runner/test:926:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:584:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A} +::debug::starting to run more tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::completed running more tests +::debug::starting to run is skipped +::debug::completed running is skipped +::debug::starting to run is a todo +::debug::completed running is a todo +::debug::starting to run top level diagnostic +::debug::completed running top level diagnostic +::notice file=tests/example.js,line=21,col=1::top level diagnostic +::group::Test results (4 passed, 2 failed) +::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json deleted file mode 100644 index d99140f..0000000 --- a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap new file mode 100644 index 0000000..74b7429 --- /dev/null +++ b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json deleted file mode 100644 index 38def42..0000000 --- a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run should fail\n::error title=should fail,file=tests/example.mjs,line=5,col=3::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Test.start (node:internal/test_runner/test:786:17)%0A at startSubtestAfterBootstrap (node:internal/test_runner/harness:280:17) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A}\n::debug::starting to run should pass\n::debug::completed running should pass\n::group::Test results (1 passed, 1 failed)\n::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap new file mode 100644 index 0000000..2e90d19 --- /dev/null +++ b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap @@ -0,0 +1,12 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run should fail +::error title=should fail,file=tests/example.mjs,line=5,col=3::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:211:14)%0A at Test.run (node:internal/test_runner/test:887:25)%0A at Test.start (node:internal/test_runner/test:786:17)%0A at startSubtestAfterBootstrap (node:internal/test_runner/harness:280:17) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A} +::debug::starting to run should pass +::debug::completed running should pass +::group::Test results (1 passed, 1 failed) +::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json deleted file mode 100644 index d046fe4..0000000 --- a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap new file mode 100644 index 0000000..40fd75d --- /dev/null +++ b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
diff --git a/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap similarity index 55% rename from packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json rename to packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap index 6b29232..e6c8120 100644 --- a/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json +++ b/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap @@ -1,5 +1,5 @@ -{ +Object { + "exitCode": 1, "stderr": "", "stdout": "", - "exitCode": 1 } \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.json b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.json deleted file mode 100644 index 3c2b389..0000000 --- a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::starting to run fails\n::error title=fails,file=tests/example.js,line=9,col=11::[Error [ERR_TEST_FAILURE]: this is an error] {%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:374:18)%0A at Test.postRun (node:internal/test_runner/test:715:19)%0A at Test.run (node:internal/test_runner/test:673:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:948:7)%0A at async startSubtest (node:internal/test_runner/harness:214:3),%0A code: 'ERR_TEST_FAILURE'%0A}\n::debug::starting to run is a diagnostic\n::debug::completed running is a diagnostic\n::notice file=tests/example.js,line=11,col=3::this is a diagnostic\n::debug::starting to run should fail\n::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:374:18)%0A at Test.postRun (node:internal/test_runner/test:715:19)%0A at Test.run (node:internal/test_runner/test:673:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:374:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A },%0A code: 'ERR_TEST_FAILURE'%0A}\n::debug::starting to run more tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::completed running more tests\n::debug::starting to run is skipped\n::debug::completed running is skipped\n::debug::starting to run is a todo\n::debug::completed running is a todo\n::debug::starting to run top level diagnostic\n::debug::completed running top level diagnostic\n::notice file=tests/example.js,line=21,col=1::top level diagnostic\n::group::Test results (4 passed, 2 failed)\n::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.snap b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.snap new file mode 100644 index 0000000..0447084 --- /dev/null +++ b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/0.snap @@ -0,0 +1,29 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::starting to run fails +::error title=fails,file=tests/example.js,line=9,col=11::[Error [ERR_TEST_FAILURE]: this is an error] {%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:374:18)%0A at Test.postRun (node:internal/test_runner/test:715:19)%0A at Test.run (node:internal/test_runner/test:673:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:948:7)%0A at async startSubtest (node:internal/test_runner/harness:214:3),%0A code: 'ERR_TEST_FAILURE'%0A} +::debug::starting to run is a diagnostic +::debug::completed running is a diagnostic +::notice file=tests/example.js,line=11,col=3::this is a diagnostic +::debug::starting to run should fail +::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:374:18)%0A at Test.postRun (node:internal/test_runner/test:715:19)%0A at Test.run (node:internal/test_runner/test:673:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:374:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A },%0A code: 'ERR_TEST_FAILURE'%0A} +::debug::starting to run more tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::completed running more tests +::debug::starting to run is skipped +::debug::completed running is skipped +::debug::starting to run is a todo +::debug::completed running is a todo +::debug::starting to run top level diagnostic +::debug::completed running top level diagnostic +::notice file=tests/example.js,line=21,col=1::top level diagnostic +::group::Test results (4 passed, 2 failed) +::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.json b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.json deleted file mode 100644 index d99140f..0000000 --- a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.snap b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.snap new file mode 100644 index 0000000..74b7429 --- /dev/null +++ b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/1.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.json b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.json deleted file mode 100644 index 3df42bd..0000000 --- a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run should fail\n::error title=should fail,file=tests/example.mjs,line=5,col=3::[Error [ERR_TEST_FAILURE]: false == true] {%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: false == true%0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Test.start (node:internal/test_runner/test:542:17)%0A at startSubtest (node:internal/test_runner/harness:214:17) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A },%0A code: 'ERR_TEST_FAILURE'%0A}\n::debug::starting to run should pass\n::debug::completed running should pass\n::group::Test results (1 passed, 1 failed)\n::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.snap b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.snap new file mode 100644 index 0000000..8f9eb5a --- /dev/null +++ b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/2.snap @@ -0,0 +1,12 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run should fail +::error title=should fail,file=tests/example.mjs,line=5,col=3::[Error [ERR_TEST_FAILURE]: false == true] {%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: false == true%0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:203:9)%0A at Test.run (node:internal/test_runner/test:631:25)%0A at Test.start (node:internal/test_runner/test:542:17)%0A at startSubtest (node:internal/test_runner/harness:214:17) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A },%0A code: 'ERR_TEST_FAILURE'%0A} +::debug::starting to run should pass +::debug::completed running should pass +::group::Test results (1 passed, 1 failed) +::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.json b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.json deleted file mode 100644 index d046fe4..0000000 --- a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.snap b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.snap new file mode 100644 index 0000000..40fd75d --- /dev/null +++ b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/3.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
diff --git a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.snap similarity index 55% rename from packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json rename to packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.snap index 6b29232..e6c8120 100644 --- a/packages/github/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json +++ b/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.snap @@ -1,5 +1,5 @@ -{ +Object { + "exitCode": 1, "stderr": "", "stdout": "", - "exitCode": 1 } \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json deleted file mode 100644 index e9d0d52..0000000 --- a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::starting to run fails\n::error title=fails,file=tests/example.js,line=9,col=11::Error [ERR_TEST_FAILURE]: this is an error%0A at async Promise.all (index 0) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at Test.postRun (node:internal/test_runner/test:885:19)%0A at Test.run (node:internal/test_runner/test:831:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:1131:7)%0A at async Test.processPendingSubtests (node:internal/test_runner/test:517:7)%0A}\n::debug::starting to run is a diagnostic\n::debug::completed running is a diagnostic\n::notice file=tests/example.js,line=11,col=3::this is a diagnostic\n::debug::starting to run should fail\n::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at Test.postRun (node:internal/test_runner/test:885:19)%0A at Test.run (node:internal/test_runner/test:831:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:517:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A}\n::debug::starting to run more tests\n::debug::starting to run is ok\n::debug::completed running is ok\n::debug::completed running more tests\n::debug::starting to run is skipped\n::debug::completed running is skipped\n::debug::starting to run is a todo\n::debug::completed running is a todo\n::debug::starting to run top level diagnostic\n::debug::completed running top level diagnostic\n::notice file=tests/example.js,line=21,col=1::top level diagnostic\n::group::Test results (4 passed, 2 failed)\n::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap new file mode 100644 index 0000000..cd829a5 --- /dev/null +++ b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap @@ -0,0 +1,29 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::starting to run fails +::error title=fails,file=tests/example.js,line=9,col=11::Error [ERR_TEST_FAILURE]: this is an error%0A at async Promise.all (index 0) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: Error: this is an error%0A at TestContext. (CWD/tests/example.js:9:11)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at Test.postRun (node:internal/test_runner/test:885:19)%0A at Test.run (node:internal/test_runner/test:831:12)%0A at async Promise.all (index 0)%0A at async Suite.run (node:internal/test_runner/test:1131:7)%0A at async Test.processPendingSubtests (node:internal/test_runner/test:517:7)%0A} +::debug::starting to run is a diagnostic +::debug::completed running is a diagnostic +::notice file=tests/example.js,line=11,col=3::this is a diagnostic +::debug::starting to run should fail +::error title=should fail,file=tests/example.js,line=12,col=31::[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A] {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (CWD/tests/example.js:12:31)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Suite.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at Test.postRun (node:internal/test_runner/test:885:19)%0A at Test.run (node:internal/test_runner/test:831:12)%0A at async Suite.processPendingSubtests (node:internal/test_runner/test:517:7) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A} +::debug::starting to run more tests +::debug::starting to run is ok +::debug::completed running is ok +::debug::completed running more tests +::debug::starting to run is skipped +::debug::completed running is skipped +::debug::starting to run is a todo +::debug::completed running is a todo +::debug::starting to run top level diagnostic +::debug::completed running top level diagnostic +::notice file=tests/example.js,line=21,col=1::top level diagnostic +::group::Test results (4 passed, 2 failed) +::notice::Total Tests: 8%0ASuites 📂: 2%0APassed ✅: 4%0AFailed ❌: 2%0ACanceled 🚫: 0%0ASkipped ⏭️: 1%0ATodo 📝: 1%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json deleted file mode 100644 index d99140f..0000000 --- a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap new file mode 100644 index 0000000..74b7429 --- /dev/null +++ b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests8
Suites 📂2
Passed ✅4
Failed ❌2
Canceled 🚫0
Skipped ⏭️1
Todo 📝1
Duration 🕐*ms
diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json deleted file mode 100644 index c51c75a..0000000 --- a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "::debug::starting to run should fail\n::error title=should fail,file=tests/example.mjs,line=5,col=3::Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A%0A at AsyncResource.runInAsyncScope (node:async_hooks:206:9) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Test.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at node:internal/test_runner/harness:252:12%0A at node:internal/process/task_queues:140:7%0A at AsyncResource.runInAsyncScope (node:async_hooks:206:9)%0A at AsyncResource.runMicrotask (node:internal/process/task_queues:137:8) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A}\n::debug::starting to run should pass\n::debug::completed running should pass\n::group::Test results (1 passed, 1 failed)\n::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms\n::endgroup::\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap new file mode 100644 index 0000000..57d67c4 --- /dev/null +++ b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap @@ -0,0 +1,12 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "::debug::starting to run should fail +::error title=should fail,file=tests/example.mjs,line=5,col=3::Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:%0A%0A assert(false)%0A%0A at AsyncResource.runInAsyncScope (node:async_hooks:206:9) {%0A code: 'ERR_TEST_FAILURE',%0A failureType: 'testCodeFailure',%0A cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:%0A %0A assert(false)%0A %0A at TestContext. (file://CWD/tests/example.mjs:5:3)%0A at Test.runInAsyncScope (node:async_hooks:206:9)%0A at Test.run (node:internal/test_runner/test:789:25)%0A at Test.processPendingSubtests (node:internal/test_runner/test:517:18)%0A at node:internal/test_runner/harness:252:12%0A at node:internal/process/task_queues:140:7%0A at AsyncResource.runInAsyncScope (node:async_hooks:206:9)%0A at AsyncResource.runMicrotask (node:internal/process/task_queues:137:8) {%0A generatedMessage: true,%0A code: 'ERR_ASSERTION',%0A actual: false,%0A expected: true,%0A operator: '=='%0A }%0A} +::debug::starting to run should pass +::debug::completed running should pass +::group::Test results (1 passed, 1 failed) +::notice::Total Tests: 2%0ASuites 📂: 0%0APassed ✅: 1%0AFailed ❌: 1%0ACanceled 🚫: 0%0ASkipped ⏭️: 0%0ATodo 📝: 0%0ADuration 🕐: *ms +::endgroup:: +", +} \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json deleted file mode 100644 index d046fe4..0000000 --- a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json +++ /dev/null @@ -1 +0,0 @@ -"

Test Results

\n
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
\n" \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap new file mode 100644 index 0000000..40fd75d --- /dev/null +++ b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap @@ -0,0 +1,2 @@ +

Test Results

+
Total Tests2
Suites 📂0
Passed ✅1
Failed ❌1
Canceled 🚫0
Skipped ⏭️0
Todo 📝0
Duration 🕐*ms
diff --git a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.json b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap similarity index 55% rename from packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.json rename to packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap index 6b29232..e6c8120 100644 --- a/packages/github/.snapshots/4353502ed400317a687af8c8312f2662/4.json +++ b/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap @@ -1,5 +1,5 @@ -{ +Object { + "exitCode": 1, "stderr": "", "stdout": "", - "exitCode": 1 } \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json deleted file mode 100644 index 4d44ab7..0000000 --- a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\n\t\t\n\t\t\t\nError [ERR_TEST_FAILURE]: this is an error\n at async Promise.all (index 0) {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: Error: this is an error\n *\n *\n *\n *\n *\n *\n at async Promise.all (index 0)\n *\n *\n}\n\t\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t\n[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n] {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:\n \n assert(false)\n \n *\n *\n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n }\n}\n\t\t\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap new file mode 100644 index 0000000..00f7c5c --- /dev/null +++ b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap @@ -0,0 +1,69 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + + + +Error [ERR_TEST_FAILURE]: this is an error + at async Promise.all (index 0) { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: Error: this is an error + * + * + * + * + * + * + at async Promise.all (index 0) + * + * +} + + + + + +[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) +] { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value: + + assert(false) + + * + * + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + } +} + + + + + + + + + + + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json deleted file mode 100644 index 8412e9d..0000000 --- a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\n[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n] {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:\n \n assert(false)\n \n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n }\n}\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap new file mode 100644 index 0000000..f4a1e77 --- /dev/null +++ b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap @@ -0,0 +1,35 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + +[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) +] { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value: + + assert(false) + + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + } +} + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json deleted file mode 100644 index 3f20a94..0000000 --- a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json +++ /dev/null @@ -1,5 +0,0 @@ -[ - "\n", - "\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap new file mode 100644 index 0000000..4a7dead --- /dev/null +++ b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap @@ -0,0 +1,8 @@ +Array [ + " +", + " +", + " +", +] \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json deleted file mode 100644 index 9493fc6..0000000 --- a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json +++ /dev/null @@ -1,6 +0,0 @@ -[ - "\n", - "\n", - "\t\n\t\n\t\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap new file mode 100644 index 0000000..481e41b --- /dev/null +++ b/packages/junit/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap @@ -0,0 +1,12 @@ +Array [ + " +", + " +", + " + + +", + " +", +] \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.json b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.json deleted file mode 100644 index 411bf85..0000000 --- a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\n\t\t\n\t\t\t\n[Error [ERR_TEST_FAILURE]: this is an error] {\n failureType: 'testCodeFailure',\n cause: Error: this is an error\n *\n *\n *\n *\n *\n *\n at async Promise.all (index 0)\n *\n at async startSubtest (node:internal/test_runner/harness:214:3),\n code: 'ERR_TEST_FAILURE'\n}\n\t\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t\n[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n] {\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:\n \n assert(false)\n \n *\n *\n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n },\n code: 'ERR_TEST_FAILURE'\n}\n\t\t\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.snap b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.snap new file mode 100644 index 0000000..e325e49 --- /dev/null +++ b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/0.snap @@ -0,0 +1,68 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + + + +[Error [ERR_TEST_FAILURE]: this is an error] { + failureType: 'testCodeFailure', + cause: Error: this is an error + * + * + * + * + * + * + at async Promise.all (index 0) + * + at async startSubtest (node:internal/test_runner/harness:214:3), + code: 'ERR_TEST_FAILURE' +} + + + + + +[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) +] { + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value: + + assert(false) + + * + * + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + }, + code: 'ERR_TEST_FAILURE' +} + + + + + + + + + + + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.json b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.json deleted file mode 100644 index 9692f7c..0000000 --- a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\n[Error [ERR_TEST_FAILURE]: false == true] {\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: false == true\n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n },\n code: 'ERR_TEST_FAILURE'\n}\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.snap b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.snap new file mode 100644 index 0000000..8b893db --- /dev/null +++ b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/1.snap @@ -0,0 +1,29 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + +[Error [ERR_TEST_FAILURE]: false == true] { + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: false == true + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + }, + code: 'ERR_TEST_FAILURE' +} + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.json b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.json deleted file mode 100644 index 3f20a94..0000000 --- a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.json +++ /dev/null @@ -1,5 +0,0 @@ -[ - "\n", - "\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.snap b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.snap new file mode 100644 index 0000000..4a7dead --- /dev/null +++ b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/2.snap @@ -0,0 +1,8 @@ +Array [ + " +", + " +", + " +", +] \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.json b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.json deleted file mode 100644 index 9493fc6..0000000 --- a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.json +++ /dev/null @@ -1,6 +0,0 @@ -[ - "\n", - "\n", - "\t\n\t\n\t\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.snap b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.snap new file mode 100644 index 0000000..481e41b --- /dev/null +++ b/packages/junit/.snapshots/4353502ed400317a687af8c8312f2662/3.snap @@ -0,0 +1,12 @@ +Array [ + " +", + " +", + " + + +", + " +", +] \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json deleted file mode 100644 index 4d44ab7..0000000 --- a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\n\t\t\n\t\t\t\nError [ERR_TEST_FAILURE]: this is an error\n at async Promise.all (index 0) {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: Error: this is an error\n *\n *\n *\n *\n *\n *\n at async Promise.all (index 0)\n *\n *\n}\n\t\t\t\n\t\t\n\t\t\n\t\t\n\t\t\t\n[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n] {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:\n \n assert(false)\n \n *\n *\n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n }\n}\n\t\t\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap new file mode 100644 index 0000000..00f7c5c --- /dev/null +++ b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap @@ -0,0 +1,69 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + + + +Error [ERR_TEST_FAILURE]: this is an error + at async Promise.all (index 0) { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: Error: this is an error + * + * + * + * + * + * + at async Promise.all (index 0) + * + * +} + + + + + +[Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) +] { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value: + + assert(false) + + * + * + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + } +} + + + + + + + + + + + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json deleted file mode 100644 index 60a3f6d..0000000 --- a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n\t\n\t\t\nError [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n * {\n code: 'ERR_TEST_FAILURE',\n failureType: 'testCodeFailure',\n cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value:\n \n assert(false)\n \n *\n *\n *\n *\n *\n *\n *\n * {\n generatedMessage: true,\n code: 'ERR_ASSERTION',\n actual: false,\n expected: true,\n operator: '=='\n }\n}\n\t\t\n\t\n\t\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap new file mode 100644 index 0000000..267c45a --- /dev/null +++ b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap @@ -0,0 +1,39 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + + +Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + * { + code: 'ERR_TEST_FAILURE', + failureType: 'testCodeFailure', + cause: AssertionError [ERR_ASSERTION]: The expression evaluated to a falsy value: + + assert(false) + + * + * + * + * + * + * + * + * { + generatedMessage: true, + code: 'ERR_ASSERTION', + actual: false, + expected: true, + operator: '==' + } +} + + + + +", +} \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json deleted file mode 100644 index 3f20a94..0000000 --- a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json +++ /dev/null @@ -1,5 +0,0 @@ -[ - "\n", - "\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap new file mode 100644 index 0000000..4a7dead --- /dev/null +++ b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap @@ -0,0 +1,8 @@ +Array [ + " +", + " +", + " +", +] \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json deleted file mode 100644 index 9493fc6..0000000 --- a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json +++ /dev/null @@ -1,6 +0,0 @@ -[ - "\n", - "\n", - "\t\n\t\n\t\n", - "\n" -] \ No newline at end of file diff --git a/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap new file mode 100644 index 0000000..481e41b --- /dev/null +++ b/packages/junit/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap @@ -0,0 +1,12 @@ +Array [ + " +", + " +", + " + + +", + " +", +] \ No newline at end of file diff --git a/packages/junit/tests/index.test.js b/packages/junit/tests/index.test.js index 5234615..6974a18 100644 --- a/packages/junit/tests/index.test.js +++ b/packages/junit/tests/index.test.js @@ -24,7 +24,10 @@ test('empty', async () => { lines.push(line); } - assert.deepStrictEqual(lines, await snapshot.snap(lines)); + assert.deepStrictEqual( + snapshot.snap.serialize(lines), + await snapshot.snap(snapshot.snap.serialize(lines)), + ); }); test('single test', async () => { @@ -32,5 +35,8 @@ test('single test', async () => { for await (const line of reporter([{ type: 'test:pass', data: { name: 'test', nesting: 0, details: { duration_ms: 100 } } }])) { lines.push(line); } - assert.deepStrictEqual(lines, await snapshot.snap(lines)); + assert.deepStrictEqual( + snapshot.snap.serialize(lines), + await snapshot.snap(snapshot.snap.serialize(lines)), + ); }); diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json deleted file mode 100644 index 8f79c1a..0000000 --- a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n tests\n ✔ is ok\n 1) fails\n ✔ is a diagnostic\n 2) should fail\n\n more tests\n ✔ is ok\n\n - is skipped\n - is a todo\n ✔ top level diagnostic\n\n 4 passing (*ms)\n 2 pending\n 2 failing\n\n 1) \n tests\n fails:\n Error [ERR_TEST_FAILURE]: this is an error\n at async Promise.all (index 0)\n\n 2) \n tests\n should fail:\n Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n \n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap new file mode 100644 index 0000000..1f3ebe7 --- /dev/null +++ b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/0.snap @@ -0,0 +1,41 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + tests + ✔ is ok + 1) fails + ✔ is a diagnostic + 2) should fail + + more tests + ✔ is ok + + - is skipped + - is a todo + ✔ top level diagnostic + + 4 passing (*ms) + 2 pending + 2 failing + + 1) + tests + fails: + Error [ERR_TEST_FAILURE]: this is an error + at async Promise.all (index 0) + + 2) + tests + should fail: + Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json deleted file mode 100644 index b04c233..0000000 --- a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n 1) should fail\n ✔ should pass\n\n 1 passing (*ms)\n 1 failing\n\n 1) \n should fail:\n Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n \n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap new file mode 100644 index 0000000..30cc0c4 --- /dev/null +++ b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/1.snap @@ -0,0 +1,23 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + 1) should fail + ✔ should pass + + 1 passing (*ms) + 1 failing + + 1) + should fail: + Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/2.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/3.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json deleted file mode 100644 index 0caf8dc..0000000 --- a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js\n *\n *\n *\n *\n *\n *\n *\n *\n *\n * {\n code: 'ERR_MODULE_NOT_FOUND'\n}\nError: invalid reporter \"invalid\"\n *\n *\n", - "stdout": "", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap new file mode 100644 index 0000000..5fdc9a5 --- /dev/null +++ b/packages/mocha/.snapshots/1e467e89966f1dc487140f1b18eaffad/4.snap @@ -0,0 +1,21 @@ +Object { + "exitCode": 1, + "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js + * + * + * + * + * + * + * + * + * + * { + code: 'ERR_MODULE_NOT_FOUND' +} +Error: invalid reporter \"invalid\" + * + * +", + "stdout": "", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.json b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.json deleted file mode 100644 index 699c53d..0000000 --- a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n tests\n ✔ is ok\n 1) fails\n ✔ is a diagnostic\n 2) should fail\n\n more tests\n ✔ is ok\n\n - is skipped\n - is a todo\n ✔ top level diagnostic\n\n 4 passing (*ms)\n 2 pending\n 2 failing\n\n 1) \n tests\n fails:\n Error [ERR_TEST_FAILURE]: this is an error\n \n\n 2) \n tests\n should fail:\n Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n \n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.snap b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.snap new file mode 100644 index 0000000..c159afe --- /dev/null +++ b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/0.snap @@ -0,0 +1,41 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + tests + ✔ is ok + 1) fails + ✔ is a diagnostic + 2) should fail + + more tests + ✔ is ok + + - is skipped + - is a todo + ✔ top level diagnostic + + 4 passing (*ms) + 2 pending + 2 failing + + 1) + tests + fails: + Error [ERR_TEST_FAILURE]: this is an error + + + 2) + tests + should fail: + Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.json b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.json deleted file mode 100644 index 14612cf..0000000 --- a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n 1) should fail\n ✔ should pass\n\n 1 passing (*ms)\n 1 failing\n\n 1) \n should fail:\n Error [ERR_TEST_FAILURE]: false == true\n \n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.snap b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.snap new file mode 100644 index 0000000..de7e1c3 --- /dev/null +++ b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/1.snap @@ -0,0 +1,20 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + 1) should fail + ✔ should pass + + 1 passing (*ms) + 1 failing + + 1) + should fail: + Error [ERR_TEST_FAILURE]: false == true + + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.json b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.snap b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/2.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.json b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.snap b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/3.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.json b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.json deleted file mode 100644 index 0caf8dc..0000000 --- a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js\n *\n *\n *\n *\n *\n *\n *\n *\n *\n * {\n code: 'ERR_MODULE_NOT_FOUND'\n}\nError: invalid reporter \"invalid\"\n *\n *\n", - "stdout": "", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.snap b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.snap new file mode 100644 index 0000000..5fdc9a5 --- /dev/null +++ b/packages/mocha/.snapshots/4353502ed400317a687af8c8312f2662/4.snap @@ -0,0 +1,21 @@ +Object { + "exitCode": 1, + "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js + * + * + * + * + * + * + * + * + * + * { + code: 'ERR_MODULE_NOT_FOUND' +} +Error: invalid reporter \"invalid\" + * + * +", + "stdout": "", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json deleted file mode 100644 index 8f79c1a..0000000 --- a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n tests\n ✔ is ok\n 1) fails\n ✔ is a diagnostic\n 2) should fail\n\n more tests\n ✔ is ok\n\n - is skipped\n - is a todo\n ✔ top level diagnostic\n\n 4 passing (*ms)\n 2 pending\n 2 failing\n\n 1) \n tests\n fails:\n Error [ERR_TEST_FAILURE]: this is an error\n at async Promise.all (index 0)\n\n 2) \n tests\n should fail:\n Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n \n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap new file mode 100644 index 0000000..1f3ebe7 --- /dev/null +++ b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/0.snap @@ -0,0 +1,41 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + tests + ✔ is ok + 1) fails + ✔ is a diagnostic + 2) should fail + + more tests + ✔ is ok + + - is skipped + - is a todo + ✔ top level diagnostic + + 4 passing (*ms) + 2 pending + 2 failing + + 1) + tests + fails: + Error [ERR_TEST_FAILURE]: this is an error + at async Promise.all (index 0) + + 2) + tests + should fail: + Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json deleted file mode 100644 index bc9b115..0000000 --- a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "\n\n 1) should fail\n ✔ should pass\n\n 1 passing (*ms)\n 1 failing\n\n 1) \n should fail:\n Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value:\n\n assert(false)\n\n *\n\n\n\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap new file mode 100644 index 0000000..ba021de --- /dev/null +++ b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/1.snap @@ -0,0 +1,23 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": " + + 1) should fail + ✔ should pass + + 1 passing (*ms) + 1 failing + + 1) + should fail: + Error [ERR_TEST_FAILURE]: The expression evaluated to a falsy value: + + assert(false) + + * + + + +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/2.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json deleted file mode 100644 index fcad495..0000000 --- a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is ok'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests fails'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests is a diagnostic'\n}\n{\n state: 'failed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' tests should fail'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' more tests is ok'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is skipped'\n}\n{\n state: 'pending',\n isPending: true,\n currentRetry: 0,\n fullTitle: ' is a todo'\n}\n{\n state: 'passed',\n isPending: false,\n currentRetry: 0,\n fullTitle: ' top level diagnostic'\n}\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap new file mode 100644 index 0000000..d61e52e --- /dev/null +++ b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/3.snap @@ -0,0 +1,53 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is ok' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests fails' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests is a diagnostic' +} +{ + state: 'failed', + isPending: false, + currentRetry: 0, + fullTitle: ' tests should fail' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' more tests is ok' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is skipped' +} +{ + state: 'pending', + isPending: true, + currentRetry: 0, + fullTitle: ' is a todo' +} +{ + state: 'passed', + isPending: false, + currentRetry: 0, + fullTitle: ' top level diagnostic' +} +", +} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json deleted file mode 100644 index 0caf8dc..0000000 --- a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js\n *\n *\n *\n *\n *\n *\n *\n *\n *\n * {\n code: 'ERR_MODULE_NOT_FOUND'\n}\nError: invalid reporter \"invalid\"\n *\n *\n", - "stdout": "", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap new file mode 100644 index 0000000..5fdc9a5 --- /dev/null +++ b/packages/mocha/.snapshots/dc3fc117f81a81ae79e191693864201a/4.snap @@ -0,0 +1,21 @@ +Object { + "exitCode": 1, + "stderr": "Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'invalid' imported from CWD/packages/mocha/index.js + * + * + * + * + * + * + * + * + * + * { + code: 'ERR_MODULE_NOT_FOUND' +} +Error: invalid reporter \"invalid\" + * + * +", + "stdout": "", +} \ No newline at end of file diff --git a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json b/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap similarity index 55% rename from packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json rename to packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap index 6b29232..e6c8120 100644 --- a/packages/github/.snapshots/dc3fc117f81a81ae79e191693864201a/4.json +++ b/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap @@ -1,5 +1,5 @@ -{ +Object { + "exitCode": 1, "stderr": "", "stdout": "", - "exitCode": 1 } \ No newline at end of file diff --git a/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json b/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json deleted file mode 100644 index 6b29232..0000000 --- a/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap b/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap new file mode 100644 index 0000000..e6c8120 --- /dev/null +++ b/packages/silent/.snapshots/bc72bb2843f04838a97cba748b6c200f/1.snap @@ -0,0 +1,5 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "", +} \ No newline at end of file diff --git a/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json b/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json deleted file mode 100644 index b28a11c..0000000 --- a/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "stderr": "", - "stdout": "file: CWD/tests/slow_tests.js has slow tests:\n *\n *\n *\n", - "exitCode": 1 -} \ No newline at end of file diff --git a/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap b/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap new file mode 100644 index 0000000..c74c457 --- /dev/null +++ b/packages/slow/.snapshots/bc72bb2843f04838a97cba748b6c200f/0.snap @@ -0,0 +1,9 @@ +Object { + "exitCode": 1, + "stderr": "", + "stdout": "file: CWD/tests/slow_tests.js has slow tests: + * + * + * +", +} \ No newline at end of file diff --git a/tests/snap.mjs b/tests/snap.mjs new file mode 100644 index 0000000..3557d68 --- /dev/null +++ b/tests/snap.mjs @@ -0,0 +1,57 @@ +// Local fork of https://github.com/mcollina/snap + +import { createHash } from 'node:crypto' +import { dirname, join } from 'node:path' +import { fileURLToPath } from 'node:url' +import { findUp } from 'find-up'; +import { mkdir, writeFile, readFile } from 'node:fs/promises' +import slash from 'slash' + +export default function build (testPath, opts = {}) { + let counter = 0 + + const update = opts.update || !!process.env.SNAP_UPDATE + + let dir + async function init () { + if (testPath.startsWith('file:')) { + testPath = fileURLToPath(testPath) + } + const root = dirname(await findUp('package.json', { cwd: dirname(testPath) })) + const seed = slash(testPath.replace(root, '.')) + const hash = createHash('md5').update(seed).digest('hex') + const cwd = opts.cwd || join(root, '.snapshots') + dir = join(cwd, hash) + + await mkdir(dir, { recursive: true }) + } + + async function snapUpdate (obj) { + if (!dir) await init() + const file = join(dir, `${counter++}.snap`) + await writeFile(file, obj) + return obj + } + + async function snapRead (obj) { + if (!dir) await init() + const file = join(dir, `${counter++}.snap`) + try { + const data = await readFile(file, 'utf8') + return data + } catch (err) { + if (err.code === 'ENOENT') { + if (process.env.CI) { + throw new Error(`Snapshot not found for: ${testPath}`) + } else { + await writeFile(file, obj) + } + return obj + } + + throw err + } + } + + return update ? snapUpdate : snapRead +} diff --git a/tests/utils.js b/tests/utils.js index 06350f4..f6aa9d3 100644 --- a/tests/utils.js +++ b/tests/utils.js @@ -4,7 +4,7 @@ const assert = require('node:assert'); const { hostname } = require('node:os'); const { resolve } = require('node:path'); // eslint-disable-next-line import/no-unresolved -const Snap = require('@matteo.collina/snap'); +const { format: prettyFormat } = require('pretty-format'); const nodeMajor = process.versions.node.split('.')[0]; @@ -20,14 +20,21 @@ function sanitize(str) { } function snapshot(filename) { - const snap = Snap(filename); + // eslint-disable-next-line no-underscore-dangle + let snap_; + async function snap(actual) { + // eslint-disable-next-line import/extensions + snap_ ??= (await import('./snap.mjs')).default(filename); + return snap_(actual); + } async function test(child, ...args) { - const actual = { + const actual = prettyFormat({ stderr: sanitize(child.stderr?.toString() ?? ''), stdout: sanitize(child.stdout?.toString() ?? ''), exitCode: child.status, - }; - assert.deepStrictEqual(actual, await snap(actual)); + }); + const expected = await snap(actual); + assert.deepStrictEqual(actual, expected); for (const arg of args) { const a = typeof arg === 'string' ? sanitize(arg) : arg; // eslint-disable-next-line no-await-in-loop @@ -35,6 +42,7 @@ function snapshot(filename) { } } test.snap = snap; + test.snap.serialize = prettyFormat; return test; } diff --git a/yarn.lock b/yarn.lock index dbbd7da..2321f04 100644 --- a/yarn.lock +++ b/yarn.lock @@ -73,6 +73,13 @@ resolved "https://registry.yarnpkg.com/@istanbuljs/schema/-/schema-0.1.3.tgz#e45e384e4b8ec16bce2fd903af78450f6bf7ec98" integrity sha512-ZXRY4jNvVgSVQ8DL3LTcakaAtXwTVUxE81hslsyD2AtoXW/wVob10HkOJ1X/pAlcI7D+2YoZKg5do8G/w6RYgA== +"@jest/schemas@^29.6.3": + version "29.6.3" + resolved "https://registry.yarnpkg.com/@jest/schemas/-/schemas-29.6.3.tgz#430b5ce8a4e0044a7e3819663305a7b3091c8e03" + integrity sha512-mo5j5X+jIZmJQveBKeS/clAueipV7KgiX1vMgCxam1RNYiqE1w62n0/tJJnHtjW8ZHcQco5gY85jA3mi0L+nSA== + dependencies: + "@sinclair/typebox" "^0.27.8" + "@jridgewell/resolve-uri@3.1.0": version "3.1.0" resolved "https://registry.yarnpkg.com/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz#2203b118c157721addfe69d47b70465463066d78" @@ -91,14 +98,6 @@ "@jridgewell/resolve-uri" "3.1.0" "@jridgewell/sourcemap-codec" "1.4.14" -"@matteo.collina/snap@^0.3.0": - version "0.3.0" - resolved "https://registry.yarnpkg.com/@matteo.collina/snap/-/snap-0.3.0.tgz#43bbdaa05a6aa90a77dd75992e732bc1c164b15b" - integrity sha512-CtoSZVegbLSMOoDjy+5TCZFY6juqSpc7P7slP5hx5jTu28ncvouAf1QrBqeLuPimIonU+ekbtkNNOlIl/a6GFw== - dependencies: - find-up "^7.0.0" - slash "^5.1.0" - "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.yarnpkg.com/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz#7619c2eb21b25483f6d167548b4cfd5a7488c3d5" @@ -125,6 +124,11 @@ resolved "https://registry.yarnpkg.com/@pkgjs/parseargs/-/parseargs-0.11.0.tgz#a77ea742fab25775145434eb1d2328cf5013ac33" integrity sha512-+1VkjdD0QBLPodGrJUeqarH8VAIvQODIbwh9XpP5Syisf7YoQgsJKPNFoqqLQlu+VQ/tVSshMR6loPMn8U+dPg== +"@sinclair/typebox@^0.27.8": + version "0.27.8" + resolved "https://registry.yarnpkg.com/@sinclair/typebox/-/typebox-0.27.8.tgz#6667fac16c436b5434a387a34dedb013198f6e6e" + integrity sha512-+Fj43pSMwJs4KRrH/938Uf+uAELIgVBmQzg/q1YG10djyfA3TnrU8N8XzqCh/okZdszqBQTZf96idMfE5lnwTA== + "@types/istanbul-lib-coverage@^2.0.1": version "2.0.4" resolved "https://registry.yarnpkg.com/@types/istanbul-lib-coverage/-/istanbul-lib-coverage-2.0.4.tgz#8467d4b3c087805d63580480890791277ce35c44" @@ -177,6 +181,11 @@ ansi-styles@^4.0.0, ansi-styles@^4.1.0: dependencies: color-convert "^2.0.1" +ansi-styles@^5.0.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-5.2.0.tgz#07449690ad45777d1924ac2abb2fc8895dba836b" + integrity sha512-Cxwpt2SfTzTtXcfOlzGEee8O+c+MmUgGrNiBcXnuWxuFJHe6a5Hz7qwhwe5OgaSYI0IJvkLqWX1ASG+cJOkEiA== + ansi-styles@^6.1.0: version "6.2.1" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-6.2.1.tgz#0e62320cf99c21afff3b3012192546aacbfb05c5" @@ -1393,6 +1402,15 @@ prelude-ls@^1.2.1: resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.2.1.tgz#debc6489d7a6e6b0e7611888cec880337d316396" integrity sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g== +pretty-format@^29.7.0: + version "29.7.0" + resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-29.7.0.tgz#ca42c758310f365bfa71a0bda0a807160b776812" + integrity sha512-Pdlw/oPxN+aXdmM9R00JVC9WVFoCLTKJvDVLgmJ+qAffBMxsV85l/Lu7sNx4zSzPyoL2euImuEwHhOXdEgNFZQ== + dependencies: + "@jest/schemas" "^29.6.3" + ansi-styles "^5.0.0" + react-is "^18.0.0" + punycode@^2.1.0: version "2.1.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.1.1.tgz#b58b010ac40c22c5657616c8d2c2c02c7bf479ec" @@ -1410,6 +1428,11 @@ randombytes@^2.1.0: dependencies: safe-buffer "^5.1.0" +react-is@^18.0.0: + version "18.3.1" + resolved "https://registry.yarnpkg.com/react-is/-/react-is-18.3.1.tgz#e83557dc12eae63a99e003a46388b1dcbb44db7e" + integrity sha512-/LLMVyas0ljjAtoYiPqYiL8VWXzUUdThrmU5+n20DZv+a+ClRoevUzw5JxU+Ieh5/c87ytoTBV9G1FiKfNJdmg== + readdirp@~3.6.0: version "3.6.0" resolved "https://registry.yarnpkg.com/readdirp/-/readdirp-3.6.0.tgz#74a370bd857116e245b29cc97340cd431a02a6c7" @@ -1821,6 +1844,6 @@ yocto-queue@^0.1.0: integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== yocto-queue@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-1.0.0.tgz#7f816433fb2cbc511ec8bf7d263c3b58a1a3c251" - integrity sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g== + version "1.1.1" + resolved "https://registry.yarnpkg.com/yocto-queue/-/yocto-queue-1.1.1.tgz#fef65ce3ac9f8a32ceac5a634f74e17e5b232110" + integrity sha512-b4JR1PFR10y1mKjhHY9LaGo6tmrgjit7hxVIeAmyMw3jegXR4dhYqLaQF5zMXZxY7tLpMyJeLjr1C4rLmkVe8g==