sxy-test-runner 1.0.13 → 1.0.15
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/dist/cli/index.js +2 -6
- package/dist/cli/init.js +19 -14
- package/dist/cli/lib/addBasePath.js +0 -1
- package/dist/cli/lib/addBasePath.unitTest.js +3 -1
- package/dist/cli/lib/addExports.unitTest.js +4 -1
- package/dist/cli/lib/applyConfigDefaults.js +12 -7
- package/dist/cli/lib/applyConfigDefaults.unitTest.js +9 -3
- package/dist/cli/lib/buildDependencyTree.js +10 -5
- package/dist/cli/lib/buildDependencyTree.unitTest.js +3 -1
- package/dist/cli/lib/buildDependencyTrees.js +6 -4
- package/dist/cli/lib/buildDependencyTrees.unitTest.js +3 -1
- package/dist/cli/lib/defaultConfig.test.js +3 -1
- package/dist/cli/lib/doUserSetup.js +0 -3
- package/dist/cli/lib/doUserSetup.unitTest.js +3 -1
- package/dist/cli/lib/doUserTeardown.js +0 -3
- package/dist/cli/lib/doUserTeardown.unitTest.js +3 -1
- package/dist/cli/lib/findTestFiles.unitTest.js +3 -1
- package/dist/cli/lib/getAllowedFlags.js +0 -2
- package/dist/cli/lib/getAllowedFlags.unitTest.js +3 -1
- package/dist/cli/lib/injectProperties.js +2 -2
- package/dist/cli/lib/injectProperties.unitTest.js +9 -2
- package/dist/cli/lib/loadConfig.js +2 -2
- package/dist/cli/lib/loadConfig.unitTest.js +3 -2
- package/dist/cli/lib/loadTestFile.js +17 -15
- package/dist/cli/lib/loadTestFile.unitTest.js +8 -3
- package/dist/cli/lib/loadTestFileStatic.js +1 -0
- package/dist/cli/lib/loadTestFileStatic.unitTest.js +1 -0
- package/dist/cli/lib/parseCommandLineArguments.js +1 -9
- package/dist/cli/lib/parseCommandLineArguments.unitTest.js +6 -2
- package/dist/cli/lib/parseDescribe.js +12 -18
- package/dist/cli/lib/parseDescribe.unitTest.js +6 -2
- package/dist/cli/lib/processWatchEvent.unitTest.js +9 -1
- package/dist/cli/lib/reservedExportKeys.unitTest.js +3 -1
- package/dist/cli/lib/runDescribe.js +4 -7
- package/dist/cli/lib/runDescribe.old.js +19 -25
- package/dist/cli/lib/runDescribe.unitTest.js +120 -2
- package/dist/cli/lib/runDescribeRun.js +3 -7
- package/dist/cli/lib/runDescribeRun.unitTest.js +125 -4
- package/dist/cli/lib/runIt.js +16 -18
- package/dist/cli/lib/runIt.unitTest.js +124 -4
- package/dist/cli/lib/runTasks.js +2 -7
- package/dist/cli/lib/runTasks.unitTest.js +3 -1
- package/dist/cli/lib/runTest-old.js +1 -0
- package/dist/cli/lib/runTest-old.unitTest.js +1 -0
- package/dist/cli/lib/runTest.js +15 -12
- package/dist/cli/lib/runTest.unitTest.js +38 -11
- package/dist/cli/lib/runTests.js +36 -35
- package/dist/cli/lib/runTests.unitTest.js +15 -8
- package/dist/cli/lib/showTestLoadingError.js +6 -6
- package/dist/cli/lib/showTestLoadingError.unitTest.js +5 -3
- package/dist/cli/lib/showTestResult.js +10 -16
- package/dist/cli/lib/showTestResult.unitTest.js +26 -17
- package/dist/cli/lib/validateConfig.js +0 -5
- package/dist/cli/lib/validateConfig.unitTest.js +2 -3
- package/dist/cli/lib/watchFiles.unitTest.js +5 -3
- package/dist/cli/lib/watchFilesAndRunTests.js +3 -1
- package/dist/cli/lib/watchFilesAndRunTests.unitTest.js +18 -15
- package/dist/cli/lib/watchFilesAndRunTestsChokidar.js +22 -29
- package/dist/cli/lib/watchFilesAndRunTestsChokidar.unitTest.js +19 -17
- package/dist/cli/lib/watchFilesAndRunTestsNodeWatch.js +28 -31
- package/dist/cli/lib/watchFilesAndRunTestsNodeWatch.unitTest.js +21 -16
- package/dist/cli/lib/watchFilesChokidar.js +15 -11
- package/dist/cli/lib/watchFilesChokidar.unitTest.js +11 -8
- package/dist/cli/lib/watchFilesNodeWatch.js +9 -6
- package/dist/cli/lib/watchFilesNodeWatch.unitTest.js +6 -3
- package/dist/cli/once.js +0 -6
- package/dist/cli/watch.js +18 -14
- package/dist/cli/watch.unitTest.js +16 -16
- package/dist/describe-old.js +35 -20
- package/dist/describe-old.unitTest.js +10 -1
- package/dist/describe.js +8 -3
- package/dist/describe.unitTest.js +5 -2
- package/dist/indexNumberToLetters.js +1 -3
- package/dist/output.js +7 -0
- package/dist/testsState.js +2 -1
- package/package.json +14 -7
- package/readme.md +1 -1
- package/sxy-loader.config.js +10 -10
package/dist/output.js
CHANGED
|
@@ -1,17 +1,24 @@
|
|
|
1
1
|
/* eslint-disable no-console */
|
|
2
|
+
|
|
2
3
|
import { debugging } from './config.js';
|
|
4
|
+
async function waitToOutput() {}
|
|
3
5
|
export async function out(...texts) {
|
|
6
|
+
await waitToOutput();
|
|
4
7
|
await console.log(...texts);
|
|
5
8
|
}
|
|
6
9
|
export async function warn(...texts) {
|
|
10
|
+
await waitToOutput();
|
|
7
11
|
await console.log(...texts);
|
|
8
12
|
}
|
|
9
13
|
export async function error(...texts) {
|
|
14
|
+
await waitToOutput();
|
|
10
15
|
await console.log(...texts);
|
|
11
16
|
}
|
|
12
17
|
export async function log(...texts) {
|
|
18
|
+
await waitToOutput();
|
|
13
19
|
await console.log(...texts);
|
|
14
20
|
}
|
|
15
21
|
export const debug = debugging ? async function debug(...texts) {
|
|
22
|
+
await waitToOutput();
|
|
16
23
|
await console.log(...texts);
|
|
17
24
|
} : async function () {};
|
package/dist/testsState.js
CHANGED
package/package.json
CHANGED
|
@@ -1,7 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "sxy-test-runner",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.15",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
|
+
"homepage": "https://github.com/RobertSandiford/sxy-test-runner",
|
|
6
|
+
"repository": {
|
|
7
|
+
"type": "git",
|
|
8
|
+
"url": "https://github.com/RobertSandiford/sxy-test-runner"
|
|
9
|
+
},
|
|
5
10
|
"type": "module",
|
|
6
11
|
"main": "./dist/index.js",
|
|
7
12
|
"module": "./dist/index.js",
|
|
@@ -40,7 +45,7 @@
|
|
|
40
45
|
"mocha-trial": "mocha --watch --parallel --config unitTesting/.mocharc.cjs --watch-files dist,unitTesting dist/**/runTest.unitTest.js"
|
|
41
46
|
},
|
|
42
47
|
"dependencies": {
|
|
43
|
-
"@babel/core": "^7.
|
|
48
|
+
"@babel/core": "^7.21.4",
|
|
44
49
|
"chalk-extensions": "^1.0.1",
|
|
45
50
|
"chokidar": "^3.5.3",
|
|
46
51
|
"cross-env": "^7.0.3",
|
|
@@ -48,17 +53,19 @@
|
|
|
48
53
|
"figures": "^4.0.1",
|
|
49
54
|
"glob": "^7.2.3",
|
|
50
55
|
"globby": "^12.2.0",
|
|
51
|
-
"minimatch": "^5.1.
|
|
56
|
+
"minimatch": "^5.1.6",
|
|
52
57
|
"node-watch": "^0.7.3",
|
|
53
58
|
"slash": "^5.0.0",
|
|
54
59
|
"sxy-dev-tools": "^1.0.6",
|
|
55
60
|
"sxy-helpers": "^1.0.0",
|
|
56
|
-
"sxy-
|
|
57
|
-
"sxy-
|
|
61
|
+
"sxy-lib": "^1.0.12",
|
|
62
|
+
"sxy-lib-object-copy": "^1.0.5",
|
|
63
|
+
"sxy-loader": "^2.0.19",
|
|
64
|
+
"sxy-standard": "^1.0.12",
|
|
58
65
|
"sxy-standard-object-copy": "^1.0.5"
|
|
59
66
|
},
|
|
60
67
|
"devDependencies": {
|
|
61
|
-
"@babel/cli": "^7.
|
|
68
|
+
"@babel/cli": "^7.21.0",
|
|
62
69
|
"babel-plugin-transform-awaitful": "^1.0.0",
|
|
63
70
|
"chai": "^4.3.7",
|
|
64
71
|
"chai-as-promised": "^7.1.1",
|
|
@@ -66,7 +73,7 @@
|
|
|
66
73
|
"eslint-config-sandi": "^1.2.0",
|
|
67
74
|
"mocha": "^9.2.2",
|
|
68
75
|
"mocha-steps": "^1.3.0",
|
|
69
|
-
"nodemon": "^2.0.
|
|
76
|
+
"nodemon": "^2.0.22",
|
|
70
77
|
"sinon": "^12.0.1",
|
|
71
78
|
"sinon-chai": "^3.7.0"
|
|
72
79
|
}
|
package/readme.md
CHANGED
|
@@ -203,4 +203,4 @@ describe('something', ({it, beforeEachTest, afterEachTest, afterDescribe}) => {
|
|
|
203
203
|
|
|
204
204
|
# Known issues
|
|
205
205
|
|
|
206
|
-
sxy-loader uses eval to
|
|
206
|
+
sxy-loader effectively uses eval to run modules, to get around the ESM limited of being unable to reload modules. This has a harmful effect on error reporting when code hits errors. I have some plans to work on error reporting, or work to get changes made to the ESM spec, but at current time error reporting isn't great.
|
package/sxy-loader.config.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
export default {
|
|
3
|
-
//returnStyle: 'esm-dynamic', // 'esm-dynamic' | 'esm-static'
|
|
4
|
-
mode: process.env.NODE_ENV, // 'development' | 'production' environment
|
|
5
|
-
//transformCaching: 'content', // content | hash | false // default content
|
|
6
|
-
//transformCacheStorage: 'file', // 'file' | 'memory'
|
|
7
|
-
//transformCacheStorageLocation: '__cache', // null | path/to/location/from/project/dir
|
|
8
|
-
quiet: true, // disable info output
|
|
9
|
-
debug: false, // debugging output // doesn't work yet
|
|
10
|
-
}
|
|
1
|
+
|
|
2
|
+
export default {
|
|
3
|
+
//returnStyle: 'esm-dynamic', // 'esm-dynamic' | 'esm-static'
|
|
4
|
+
mode: process.env.NODE_ENV, // 'development' | 'production' environment
|
|
5
|
+
//transformCaching: 'content', // content | hash | false // default content
|
|
6
|
+
//transformCacheStorage: 'file', // 'file' | 'memory'
|
|
7
|
+
//transformCacheStorageLocation: '__cache', // null | path/to/location/from/project/dir
|
|
8
|
+
quiet: true, // disable info output
|
|
9
|
+
debug: false, // debugging output // doesn't work yet
|
|
10
|
+
}
|