tsds-web-test-runner 1.9.1 → 1.9.4
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/cjs/command.js
CHANGED
|
@@ -49,7 +49,7 @@ function _object_without_properties_loose(source, excluded) {
|
|
|
49
49
|
}
|
|
50
50
|
return target;
|
|
51
51
|
}
|
|
52
|
-
var __dirname = _path.default.dirname(typeof __filename
|
|
52
|
+
var __dirname = _path.default.dirname(typeof __filename === 'undefined' ? _url.default.fileURLToPath(require("url").pathToFileURL(__filename).toString()) : __filename);
|
|
53
53
|
var major = +process.versions.node.split('.')[0];
|
|
54
54
|
var workerWrapper = (0, _tsdslib.wrapWorker)(_path.default.join((0, _modulerootsync.default)(__dirname), 'dist', 'cjs', 'command.js'));
|
|
55
55
|
var config = _path.default.resolve((0, _modulerootsync.default)(__dirname), 'dist', 'esm', 'wtr.config.mjs');
|
|
@@ -58,9 +58,7 @@ function worker(args, options, callback) {
|
|
|
58
58
|
(0, _linkunlink.link)(cwd, (0, _tsdslib.installPath)(options), function(err, restore) {
|
|
59
59
|
if (err) return callback(err);
|
|
60
60
|
try {
|
|
61
|
-
var wtr = (0, _resolvebinsync.default)('@web/test-runner',
|
|
62
|
-
executable: 'wtr'
|
|
63
|
-
});
|
|
61
|
+
var wtr = (0, _resolvebinsync.default)('@web/test-runner', 'wtr');
|
|
64
62
|
var _getopts = (0, _getoptscompat.default)(args, {
|
|
65
63
|
stopEarly: true,
|
|
66
64
|
alias: {
|
package/dist/cjs/command.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/typescript/ts-dev-stack/packages/tsds-web-test-runner/src/command.ts"],"sourcesContent":["import path from 'path';\nimport url from 'url';\nimport spawn from 'cross-spawn-cb';\nimport getopts from 'getopts-compat';\nimport { link, unlink } from 'link-unlink';\nimport moduleRoot from 'module-root-sync';\nimport Queue from 'queue-cb';\nimport resolveBin from 'resolve-bin-sync';\nimport { installPath, wrapWorker } from 'tsds-lib';\n\nconst __dirname = path.dirname(typeof __filename
|
|
1
|
+
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/typescript/ts-dev-stack/packages/tsds-web-test-runner/src/command.ts"],"sourcesContent":["import path from 'path';\nimport url from 'url';\nimport spawn from 'cross-spawn-cb';\nimport getopts from 'getopts-compat';\nimport { link, unlink } from 'link-unlink';\nimport moduleRoot from 'module-root-sync';\nimport Queue from 'queue-cb';\nimport resolveBin from 'resolve-bin-sync';\nimport { installPath, wrapWorker } from 'tsds-lib';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst workerWrapper = wrapWorker(path.join(moduleRoot(__dirname), 'dist', 'cjs', 'command.js'));\nconst config = path.resolve(moduleRoot(__dirname), 'dist', 'esm', 'wtr.config.mjs');\n\nfunction worker(args, options, callback) {\n const cwd = options.cwd || process.cwd();\n\n link(cwd, installPath(options), (err, restore) => {\n if (err) return callback(err);\n\n try {\n const wtr = resolveBin('@web/test-runner', 'wtr');\n const { _, ...opts } = getopts(args, { stopEarly: true, alias: { config: 'c' } });\n const spawnArgs = [wtr];\n if (!opts.config) Array.prototype.push.apply(spawnArgs, ['--config', config]);\n Array.prototype.push.apply(spawnArgs, args);\n if (_.length === 0) Array.prototype.push.apply(spawnArgs, ['test/**/*.test.{ts,tsx,jsx,mjs}']);\n\n const queue = new Queue(1);\n queue.defer(spawn.bind(null, spawnArgs[0], spawnArgs.slice(1), options));\n queue.await((err) => unlink(restore, callback.bind(err)));\n } catch (err) {\n callback(err);\n }\n });\n}\n\nexport default function testBrowser(args, options, cb) {\n major < 14 ? workerWrapper('stable', args, options, cb) : worker(args, options, cb);\n}\n"],"names":["testBrowser","__dirname","path","dirname","__filename","url","fileURLToPath","major","process","versions","node","split","workerWrapper","wrapWorker","join","moduleRoot","config","resolve","worker","args","options","callback","cwd","link","installPath","err","restore","wtr","resolveBin","getopts","stopEarly","alias","_","opts","spawnArgs","Array","prototype","push","apply","length","queue","Queue","defer","spawn","bind","slice","await","unlink","cb"],"mappings":";;;;+BAsCA;;;eAAwBA;;;2DAtCP;0DACD;mEACE;oEACE;0BACS;qEACN;8DACL;qEACK;uBACiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAExC,IAAMC,YAAYC,aAAI,CAACC,OAAO,CAAC,OAAOC,eAAe,cAAcC,YAAG,CAACC,aAAa,CAAC,uDAAmBF;AACxG,IAAMG,QAAQ,CAACC,QAAQC,QAAQ,CAACC,IAAI,CAACC,KAAK,CAAC,IAAI,CAAC,EAAE;AAClD,IAAMC,gBAAgBC,IAAAA,mBAAU,EAACX,aAAI,CAACY,IAAI,CAACC,IAAAA,uBAAU,EAACd,YAAY,QAAQ,OAAO;AACjF,IAAMe,SAASd,aAAI,CAACe,OAAO,CAACF,IAAAA,uBAAU,EAACd,YAAY,QAAQ,OAAO;AAElE,SAASiB,OAAOC,IAAI,EAAEC,OAAO,EAAEC,QAAQ;IACrC,IAAMC,MAAMF,QAAQE,GAAG,IAAId,QAAQc,GAAG;IAEtCC,IAAAA,gBAAI,EAACD,KAAKE,IAAAA,oBAAW,EAACJ,UAAU,SAACK,KAAKC;QACpC,IAAID,KAAK,OAAOJ,SAASI;QAEzB,IAAI;YACF,IAAME,MAAMC,IAAAA,uBAAU,EAAC,oBAAoB;YAC3C,IAAuBC,WAAAA,IAAAA,sBAAO,EAACV,MAAM;gBAAEW,WAAW;gBAAMC,OAAO;oBAAEf,QAAQ;gBAAI;YAAE,IAAzE,AAAEgB,IAAeH,SAAfG,GAAMC,kCAASJ;gBAAfG;;YACR,IAAME,YAAY;gBAACP;aAAI;YACvB,IAAI,CAACM,KAAKjB,MAAM,EAAEmB,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAW;gBAAC;gBAAYlB;aAAO;YAC5EmB,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAWf;YACtC,IAAIa,EAAEO,MAAM,KAAK,GAAGJ,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAW;gBAAC;aAAkC;YAE7F,IAAMM,QAAQ,IAAIC,gBAAK,CAAC;YACxBD,MAAME,KAAK,CAACC,qBAAK,CAACC,IAAI,CAAC,MAAMV,SAAS,CAAC,EAAE,EAAEA,UAAUW,KAAK,CAAC,IAAIzB;YAC/DoB,MAAMM,KAAK,CAAC,SAACrB;uBAAQsB,IAAAA,kBAAM,EAACrB,SAASL,SAASuB,IAAI,CAACnB;;QACrD,EAAE,OAAOA,KAAK;YACZJ,SAASI;QACX;IACF;AACF;AAEe,SAASzB,YAAYmB,IAAI,EAAEC,OAAO,EAAE4B,EAAE;IACnDzC,QAAQ,KAAKK,cAAc,UAAUO,MAAMC,SAAS4B,MAAM9B,OAAOC,MAAMC,SAAS4B;AAClF"}
|
package/dist/esm/command.mjs
CHANGED
|
@@ -7,7 +7,7 @@ import moduleRoot from 'module-root-sync';
|
|
|
7
7
|
import Queue from 'queue-cb';
|
|
8
8
|
import resolveBin from 'resolve-bin-sync';
|
|
9
9
|
import { installPath, wrapWorker } from 'tsds-lib';
|
|
10
|
-
const __dirname = path.dirname(typeof __filename
|
|
10
|
+
const __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);
|
|
11
11
|
const major = +process.versions.node.split('.')[0];
|
|
12
12
|
const workerWrapper = wrapWorker(path.join(moduleRoot(__dirname), 'dist', 'cjs', 'command.js'));
|
|
13
13
|
const config = path.resolve(moduleRoot(__dirname), 'dist', 'esm', 'wtr.config.mjs');
|
|
@@ -16,9 +16,7 @@ function worker(args, options, callback) {
|
|
|
16
16
|
link(cwd, installPath(options), (err, restore)=>{
|
|
17
17
|
if (err) return callback(err);
|
|
18
18
|
try {
|
|
19
|
-
const wtr = resolveBin('@web/test-runner',
|
|
20
|
-
executable: 'wtr'
|
|
21
|
-
});
|
|
19
|
+
const wtr = resolveBin('@web/test-runner', 'wtr');
|
|
22
20
|
const { _, ...opts } = getopts(args, {
|
|
23
21
|
stopEarly: true,
|
|
24
22
|
alias: {
|
package/dist/esm/command.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/typescript/ts-dev-stack/packages/tsds-web-test-runner/src/command.ts"],"sourcesContent":["import path from 'path';\nimport url from 'url';\nimport spawn from 'cross-spawn-cb';\nimport getopts from 'getopts-compat';\nimport { link, unlink } from 'link-unlink';\nimport moduleRoot from 'module-root-sync';\nimport Queue from 'queue-cb';\nimport resolveBin from 'resolve-bin-sync';\nimport { installPath, wrapWorker } from 'tsds-lib';\n\nconst __dirname = path.dirname(typeof __filename
|
|
1
|
+
{"version":3,"sources":["/Users/kevin/Dev/OpenSource/typescript/ts-dev-stack/packages/tsds-web-test-runner/src/command.ts"],"sourcesContent":["import path from 'path';\nimport url from 'url';\nimport spawn from 'cross-spawn-cb';\nimport getopts from 'getopts-compat';\nimport { link, unlink } from 'link-unlink';\nimport moduleRoot from 'module-root-sync';\nimport Queue from 'queue-cb';\nimport resolveBin from 'resolve-bin-sync';\nimport { installPath, wrapWorker } from 'tsds-lib';\n\nconst __dirname = path.dirname(typeof __filename === 'undefined' ? url.fileURLToPath(import.meta.url) : __filename);\nconst major = +process.versions.node.split('.')[0];\nconst workerWrapper = wrapWorker(path.join(moduleRoot(__dirname), 'dist', 'cjs', 'command.js'));\nconst config = path.resolve(moduleRoot(__dirname), 'dist', 'esm', 'wtr.config.mjs');\n\nfunction worker(args, options, callback) {\n const cwd = options.cwd || process.cwd();\n\n link(cwd, installPath(options), (err, restore) => {\n if (err) return callback(err);\n\n try {\n const wtr = resolveBin('@web/test-runner', 'wtr');\n const { _, ...opts } = getopts(args, { stopEarly: true, alias: { config: 'c' } });\n const spawnArgs = [wtr];\n if (!opts.config) Array.prototype.push.apply(spawnArgs, ['--config', config]);\n Array.prototype.push.apply(spawnArgs, args);\n if (_.length === 0) Array.prototype.push.apply(spawnArgs, ['test/**/*.test.{ts,tsx,jsx,mjs}']);\n\n const queue = new Queue(1);\n queue.defer(spawn.bind(null, spawnArgs[0], spawnArgs.slice(1), options));\n queue.await((err) => unlink(restore, callback.bind(err)));\n } catch (err) {\n callback(err);\n }\n });\n}\n\nexport default function testBrowser(args, options, cb) {\n major < 14 ? workerWrapper('stable', args, options, cb) : worker(args, options, cb);\n}\n"],"names":["path","url","spawn","getopts","link","unlink","moduleRoot","Queue","resolveBin","installPath","wrapWorker","__dirname","dirname","__filename","fileURLToPath","major","process","versions","node","split","workerWrapper","join","config","resolve","worker","args","options","callback","cwd","err","restore","wtr","_","opts","stopEarly","alias","spawnArgs","Array","prototype","push","apply","length","queue","defer","bind","slice","await","testBrowser","cb"],"mappings":"AAAA,OAAOA,UAAU,OAAO;AACxB,OAAOC,SAAS,MAAM;AACtB,OAAOC,WAAW,iBAAiB;AACnC,OAAOC,aAAa,iBAAiB;AACrC,SAASC,IAAI,EAAEC,MAAM,QAAQ,cAAc;AAC3C,OAAOC,gBAAgB,mBAAmB;AAC1C,OAAOC,WAAW,WAAW;AAC7B,OAAOC,gBAAgB,mBAAmB;AAC1C,SAASC,WAAW,EAAEC,UAAU,QAAQ,WAAW;AAEnD,MAAMC,YAAYX,KAAKY,OAAO,CAAC,OAAOC,eAAe,cAAcZ,IAAIa,aAAa,CAAC,YAAYb,GAAG,IAAIY;AACxG,MAAME,QAAQ,CAACC,QAAQC,QAAQ,CAACC,IAAI,CAACC,KAAK,CAAC,IAAI,CAAC,EAAE;AAClD,MAAMC,gBAAgBV,WAAWV,KAAKqB,IAAI,CAACf,WAAWK,YAAY,QAAQ,OAAO;AACjF,MAAMW,SAAStB,KAAKuB,OAAO,CAACjB,WAAWK,YAAY,QAAQ,OAAO;AAElE,SAASa,OAAOC,IAAI,EAAEC,OAAO,EAAEC,QAAQ;IACrC,MAAMC,MAAMF,QAAQE,GAAG,IAAIZ,QAAQY,GAAG;IAEtCxB,KAAKwB,KAAKnB,YAAYiB,UAAU,CAACG,KAAKC;QACpC,IAAID,KAAK,OAAOF,SAASE;QAEzB,IAAI;YACF,MAAME,MAAMvB,WAAW,oBAAoB;YAC3C,MAAM,EAAEwB,CAAC,EAAE,GAAGC,MAAM,GAAG9B,QAAQsB,MAAM;gBAAES,WAAW;gBAAMC,OAAO;oBAAEb,QAAQ;gBAAI;YAAE;YAC/E,MAAMc,YAAY;gBAACL;aAAI;YACvB,IAAI,CAACE,KAAKX,MAAM,EAAEe,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAW;gBAAC;gBAAYd;aAAO;YAC5Ee,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAWX;YACtC,IAAIO,EAAES,MAAM,KAAK,GAAGJ,MAAMC,SAAS,CAACC,IAAI,CAACC,KAAK,CAACJ,WAAW;gBAAC;aAAkC;YAE7F,MAAMM,QAAQ,IAAInC,MAAM;YACxBmC,MAAMC,KAAK,CAACzC,MAAM0C,IAAI,CAAC,MAAMR,SAAS,CAAC,EAAE,EAAEA,UAAUS,KAAK,CAAC,IAAInB;YAC/DgB,MAAMI,KAAK,CAAC,CAACjB,MAAQxB,OAAOyB,SAASH,SAASiB,IAAI,CAACf;QACrD,EAAE,OAAOA,KAAK;YACZF,SAASE;QACX;IACF;AACF;AAEA,eAAe,SAASkB,YAAYtB,IAAI,EAAEC,OAAO,EAAEsB,EAAE;IACnDjC,QAAQ,KAAKK,cAAc,UAAUK,MAAMC,SAASsB,MAAMxB,OAAOC,MAAMC,SAASsB;AAClF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "tsds-web-test-runner",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.4",
|
|
4
4
|
"description": "Development stack for TypeScript libraries",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"c8",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"module-root-sync": "^0.1.1",
|
|
56
56
|
"queue-cb": "^1.4.4",
|
|
57
57
|
"resolve-bin-sync": "^0.1.0",
|
|
58
|
-
"tsds-lib": "^1.9.
|
|
58
|
+
"tsds-lib": "^1.9.4",
|
|
59
59
|
"webpack-merge": "^6.0.1"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
@@ -70,5 +70,5 @@
|
|
|
70
70
|
"tsds": {
|
|
71
71
|
"source": "src/index.ts"
|
|
72
72
|
},
|
|
73
|
-
"gitHead": "
|
|
73
|
+
"gitHead": "b6bc96ed5e88f582839ebdce7556fcbbb4dd0f2b"
|
|
74
74
|
}
|