@reporters/bail 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -0
- package/index.js +2 -0
- package/package.json +4 -1
- package/CHANGELOG.md +0 -15
- package/tests/fixtures/fail.js +0 -7
- package/tests/fixtures/pass.js +0 -3
- package/tests/index.test.js +0 -24
package/README.md
CHANGED
package/index.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@reporters/bail",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.2",
|
|
4
4
|
"description": "A Bail library for `node:test`",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"node:test",
|
|
@@ -8,6 +8,9 @@
|
|
|
8
8
|
"reporter",
|
|
9
9
|
"reporters"
|
|
10
10
|
],
|
|
11
|
+
"files": [
|
|
12
|
+
"./index.js"
|
|
13
|
+
],
|
|
11
14
|
"scripts": {
|
|
12
15
|
"test": "node --test-reporter=spec --test-reporter-destination=stdout --test-reporter=../github/index.js --test-reporter-destination=stdout --test"
|
|
13
16
|
},
|
package/CHANGELOG.md
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
# Changelog
|
|
2
|
-
|
|
3
|
-
## [1.1.0](https://github.com/MoLow/reporters/compare/bail-v1.0.0...bail-v1.1.0) (2023-07-05)
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
### Features
|
|
7
|
-
|
|
8
|
-
* publish with provenance ([6ee1e46](https://github.com/MoLow/reporters/commit/6ee1e46040329edeb0f40f753093b6952984f001))
|
|
9
|
-
|
|
10
|
-
## 1.0.0 (2023-06-05)
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
### Features
|
|
14
|
-
|
|
15
|
-
* add @reporters/bail package ([9a2ca5c](https://github.com/MoLow/reporters/commit/9a2ca5c98e029e6b73238adfb0f6e68da9011d87))
|
package/tests/fixtures/fail.js
DELETED
package/tests/fixtures/pass.js
DELETED
package/tests/index.test.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
const { test } = require('node:test');
|
|
2
|
-
const { spawnSync } = require('child_process');
|
|
3
|
-
const assert = require('assert');
|
|
4
|
-
|
|
5
|
-
test('pass should not interfere with passing test', () => {
|
|
6
|
-
const child = spawnSync(process.execPath, [
|
|
7
|
-
'--test-reporter', 'dot', '--test-reporter-destination', 'stdout',
|
|
8
|
-
'--test-reporter', './index.js', '--test-reporter-destination', 'stdout', 'tests/fixtures/pass.js',
|
|
9
|
-
], { env: {} });
|
|
10
|
-
assert.strictEqual(child.stderr?.toString(), '');
|
|
11
|
-
assert.strictEqual(child.stdout?.toString(), '.\n');
|
|
12
|
-
assert.strictEqual(child.status, 0);
|
|
13
|
-
});
|
|
14
|
-
|
|
15
|
-
test('fail should stop after failed test', () => {
|
|
16
|
-
const child = spawnSync(process.execPath, [
|
|
17
|
-
'--test-reporter', 'dot', '--test-reporter-destination', 'stdout',
|
|
18
|
-
'--test-reporter', './index.js', '--test-reporter-destination', 'stdout',
|
|
19
|
-
'tests/fixtures/fail.js', 'tests/fixtures/pass.js',
|
|
20
|
-
], { env: {} });
|
|
21
|
-
assert.strictEqual(child.stderr?.toString(), '');
|
|
22
|
-
assert.strictEqual(child.stdout?.toString(), 'X\n\x1B[31m✖ Bailing on failed test: fail\x1B[0m\n');
|
|
23
|
-
assert.strictEqual(child.status, 1);
|
|
24
|
-
});
|