poku 1.17.0 → 1.17.1
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 -1
- package/lib/helpers/parse-assertion.js +15 -3
- package/lib/modules/describe.js +2 -0
- package/lib/modules/it.js +2 -0
- package/lib/modules/list-files.d.ts +2 -1
- package/lib/modules/list-files.js +63 -95
- package/lib/modules/test.js +2 -0
- package/lib/polyfills/fs.d.ts +3 -2
- package/lib/polyfills/fs.js +20 -13
- package/lib/polyfills/object.d.ts +1 -1
- package/lib/polyfills/object.js +2 -1
- package/lib/services/run-tests.js +1 -1
- package/package.json +4 -4
package/README.md
CHANGED
|
@@ -46,6 +46,7 @@ Enjoying **Poku**? Give him a star to show your support 🌟
|
|
|
46
46
|
|
|
47
47
|
<img width="16" height="16" alt="check" src="https://raw.githubusercontent.com/wellwelwel/poku/main/.github/assets/readme/check.svg"> Easier and Less Verbose<br />
|
|
48
48
|
<span> </span><img width="16" height="16" alt="check" src="https://raw.githubusercontent.com/wellwelwel/poku/main/.github/assets/readme/check.svg"> [**Node.js**][node-version-url] familiar **API**<br />
|
|
49
|
+
<span> </span><img width="16" height="16" alt="check" src="https://raw.githubusercontent.com/wellwelwel/poku/main/.github/assets/readme/check.svg"> Instantly re-run related tests in `watch` mode<br />
|
|
49
50
|
<span> </span><img width="16" height="16" alt="check" src="https://raw.githubusercontent.com/wellwelwel/poku/main/.github/assets/readme/check.svg"> Run **CJS** (**CommonJS**) files directly with [**Deno**][deno-version-url]<br />
|
|
50
51
|
<span> </span><img width="16" height="16" alt="check" src="https://raw.githubusercontent.com/wellwelwel/poku/main/.github/assets/readme/check.svg"> Easily handle, **servers**, **services**, **processes**, and **ports**<br />
|
|
51
52
|
|
|
@@ -174,8 +175,8 @@ deno run npm:poku
|
|
|
174
175
|
|
|
175
176
|
- [**test**](https://poku.io/docs/documentation/helpers/test)
|
|
176
177
|
, [**describe**](https://poku.io/docs/documentation/helpers/describe) and [**it**](https://poku.io/docs/documentation/helpers/it) _(organize, group, and isolate tests)_
|
|
178
|
+
- [**watch**](https://poku.io/docs/documentation/poku/options/watch) _(watch for changes and re-run related test files)_
|
|
177
179
|
- [**beforeEach**](https://poku.io/docs/category/beforeeach-and-aftereach) and [**afterEach**](https://poku.io/docs/category/beforeeach-and-aftereach) _(hooks for test setup and teardown)_
|
|
178
|
-
- [**watch**](https://poku.io/docs/documentation/poku/options/watch) _(watch test files for changes)_
|
|
179
180
|
- [**startScript**](https://poku.io/docs/documentation/startScript) _(run **package.json** scripts in background)_
|
|
180
181
|
- [**startService**](https://poku.io/docs/documentation/startService) _(run files in background)_
|
|
181
182
|
- [**kill**](https://poku.io/docs/documentation/processes/kill) _(terminate ports, port ranges, and PIDs)_
|
|
@@ -30,14 +30,22 @@ const logs_js_1 = require("./logs.js");
|
|
|
30
30
|
const cwd = node_process_1.default.cwd();
|
|
31
31
|
const parseResultType = (type) => {
|
|
32
32
|
const recurse = (value) => {
|
|
33
|
-
if (typeof value === 'undefined'
|
|
34
|
-
|
|
35
|
-
if (typeof value === 'function' ||
|
|
33
|
+
if (typeof value === 'undefined' ||
|
|
34
|
+
typeof value === 'function' ||
|
|
36
35
|
typeof value === 'bigint' ||
|
|
36
|
+
typeof value === 'symbol' ||
|
|
37
37
|
value instanceof RegExp)
|
|
38
38
|
return String(value);
|
|
39
39
|
if (Array.isArray(value))
|
|
40
40
|
return value.map(recurse);
|
|
41
|
+
if (value instanceof Set)
|
|
42
|
+
return Array.from(value).map(recurse);
|
|
43
|
+
/* c8 ignore start */
|
|
44
|
+
if (value instanceof Map)
|
|
45
|
+
return recurse(!get_runtime_js_1.nodeVersion || get_runtime_js_1.nodeVersion >= 12
|
|
46
|
+
? Object.fromEntries(value)
|
|
47
|
+
: (0, object_js_1.fromEntries)(value));
|
|
48
|
+
/* c8 ignore stop */
|
|
41
49
|
/* c8 ignore start */
|
|
42
50
|
if (value !== null && typeof value === 'object') {
|
|
43
51
|
if (!get_runtime_js_1.nodeVersion || get_runtime_js_1.nodeVersion >= 12)
|
|
@@ -63,16 +71,20 @@ const parseAssertion = (cb, options) => __awaiter(void 0, void 0, void 0, functi
|
|
|
63
71
|
try {
|
|
64
72
|
if (typeof each_js_1.each.before.cb === 'function' && each_js_1.each.before.assert) {
|
|
65
73
|
const beforeResult = each_js_1.each.before.cb();
|
|
74
|
+
/* c8 ignore next */
|
|
66
75
|
if (beforeResult instanceof Promise)
|
|
67
76
|
yield beforeResult;
|
|
77
|
+
/* c8 ignore next */
|
|
68
78
|
}
|
|
69
79
|
const cbResult = cb();
|
|
70
80
|
if (cbResult instanceof Promise)
|
|
71
81
|
yield cbResult;
|
|
72
82
|
if (typeof each_js_1.each.after.cb === 'function' && each_js_1.each.after.assert) {
|
|
73
83
|
const afterResult = each_js_1.each.after.cb();
|
|
84
|
+
/* c8 ignore next */
|
|
74
85
|
if (afterResult instanceof Promise)
|
|
75
86
|
yield afterResult;
|
|
87
|
+
/* c8 ignore next */
|
|
76
88
|
}
|
|
77
89
|
if (typeof options.message === 'string') {
|
|
78
90
|
const message = isPoku
|
package/lib/modules/describe.js
CHANGED
|
@@ -13,6 +13,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.describe = void 0;
|
|
16
|
+
/* c8 ignore next */
|
|
16
17
|
const node_process_1 = __importDefault(require("process"));
|
|
17
18
|
const format_js_1 = require("../helpers/format.js");
|
|
18
19
|
const logs_js_1 = require("../helpers/logs.js");
|
|
@@ -20,6 +21,7 @@ const logs_js_1 = require("../helpers/logs.js");
|
|
|
20
21
|
const indentation_js_1 = require("../configs/indentation.js");
|
|
21
22
|
function describe(arg1, arg2) {
|
|
22
23
|
return __awaiter(this, void 0, void 0, function* () {
|
|
24
|
+
/* c8 ignore stop */
|
|
23
25
|
let title;
|
|
24
26
|
let cb;
|
|
25
27
|
let options;
|
package/lib/modules/it.js
CHANGED
|
@@ -13,6 +13,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.it = void 0;
|
|
16
|
+
/* c8 ignore next */
|
|
16
17
|
const node_process_1 = __importDefault(require("process"));
|
|
17
18
|
/* c8 ignore next */
|
|
18
19
|
const each_js_1 = require("../configs/each.js");
|
|
@@ -22,6 +23,7 @@ const format_js_1 = require("../helpers/format.js");
|
|
|
22
23
|
const logs_js_1 = require("../helpers/logs.js");
|
|
23
24
|
function it(...args) {
|
|
24
25
|
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
/* c8 ignore stop */
|
|
25
27
|
let message;
|
|
26
28
|
let cb;
|
|
27
29
|
if (typeof each_js_1.each.before.cb === 'function' && each_js_1.each.before.test) {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { Configs } from '../@types/list-files.js';
|
|
2
2
|
export declare const sanitizePath: (input: string, ensureTarget?: boolean) => string;
|
|
3
|
-
export declare const escapeRegExp: (string: string) => string;
|
|
4
3
|
export declare const isFile: (fullPath: string) => Promise<boolean>;
|
|
4
|
+
export declare const escapeRegExp: (string: string) => string;
|
|
5
|
+
export declare const getAllFiles: (dirPath: string, files?: string[], configs?: Configs) => Promise<string[]>;
|
|
5
6
|
export declare const listFiles: (targetDir: string, configs?: Configs) => Promise<string[]>;
|
|
@@ -1,118 +1,86 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
3
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
4
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
5
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
6
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
7
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
8
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
9
|
+
});
|
|
10
|
+
};
|
|
2
11
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
12
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
13
|
};
|
|
5
14
|
var _a;
|
|
6
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.listFiles = exports.
|
|
16
|
+
exports.listFiles = exports.getAllFiles = exports.escapeRegExp = exports.isFile = exports.sanitizePath = void 0;
|
|
17
|
+
/* c8 ignore next */
|
|
8
18
|
const node_process_1 = __importDefault(require("process"));
|
|
9
|
-
const node_fs_1 = require("fs");
|
|
10
19
|
const node_path_1 = require("path");
|
|
20
|
+
const fs_js_1 = require("../polyfills/fs.js");
|
|
11
21
|
const sanitizePath = (input, ensureTarget) => {
|
|
12
22
|
const sanitizedPath = input
|
|
13
23
|
.replace(/[/\\]+/g, node_path_1.sep) // adapting slashes according to OS
|
|
14
24
|
.replace(/(\.\.(\/|\\|$))+/g, '') // ensure the current path level
|
|
15
25
|
.replace(/[<>|^?*]+/g, ''); // removing unusual path characters
|
|
16
|
-
|
|
26
|
+
// Preventing absolute path access
|
|
27
|
+
return ensureTarget
|
|
28
|
+
? sanitizedPath.replace(/^[/\\]/, `.${node_path_1.sep}`)
|
|
29
|
+
: sanitizedPath;
|
|
17
30
|
};
|
|
18
31
|
exports.sanitizePath = sanitizePath;
|
|
32
|
+
/* c8 ignore start */
|
|
33
|
+
const isFile = (fullPath) => __awaiter(void 0, void 0, void 0, function* () { return (yield (0, fs_js_1.stat)(fullPath)).isFile(); });
|
|
34
|
+
exports.isFile = isFile;
|
|
35
|
+
/* c8 ignore stop */
|
|
36
|
+
/* c8 ignore start */
|
|
19
37
|
const escapeRegExp = (string) => string.replace(/[.*{}[\]\\]/g, '\\$&');
|
|
20
38
|
exports.escapeRegExp = escapeRegExp;
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
(0, node_fs_1.stat)(fullPath, (err, stats) => {
|
|
24
|
-
/* c8 ignore next */
|
|
25
|
-
if (err)
|
|
26
|
-
return reject(err);
|
|
27
|
-
resolve(stats.isFile());
|
|
28
|
-
});
|
|
29
|
-
});
|
|
30
|
-
};
|
|
31
|
-
exports.isFile = isFile;
|
|
39
|
+
/* c8 ignore stop */
|
|
40
|
+
/* c8 ignore start */
|
|
32
41
|
const envFilter = ((_a = node_process_1.default.env.FILTER) === null || _a === void 0 ? void 0 : _a.trim())
|
|
33
42
|
? new RegExp((0, exports.escapeRegExp)(node_process_1.default.env.FILTER), 'i')
|
|
34
43
|
: undefined;
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
(
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
44
|
+
/* c8 ignore stop */
|
|
45
|
+
const getAllFiles = (dirPath_1, ...args_1) => __awaiter(void 0, [dirPath_1, ...args_1], void 0, function* (dirPath, files = [], configs) {
|
|
46
|
+
const currentFiles = yield (0, fs_js_1.readdir)((0, exports.sanitizePath)(dirPath));
|
|
47
|
+
const defaultRegExp = /\.(test|spec)\./i;
|
|
48
|
+
/* c8 ignore start */
|
|
49
|
+
const filter = (envFilter
|
|
50
|
+
? envFilter
|
|
51
|
+
: (configs === null || configs === void 0 ? void 0 : configs.filter) instanceof RegExp
|
|
52
|
+
? configs.filter
|
|
53
|
+
: defaultRegExp) || defaultRegExp;
|
|
54
|
+
const exclude = (configs === null || configs === void 0 ? void 0 : configs.exclude)
|
|
55
|
+
? Array.isArray(configs.exclude)
|
|
56
|
+
? configs.exclude
|
|
57
|
+
: [configs.exclude]
|
|
58
|
+
: undefined;
|
|
59
|
+
/* c8 ignore stop */
|
|
60
|
+
yield Promise.all(currentFiles.map((file) => __awaiter(void 0, void 0, void 0, function* () {
|
|
61
|
+
const fullPath = (0, node_path_1.join)(dirPath, file);
|
|
62
|
+
const stat = yield (0, fs_js_1.stat)(fullPath);
|
|
63
|
+
/* c8 ignore start */
|
|
64
|
+
if (fullPath.indexOf('node_modules') !== -1 ||
|
|
65
|
+
fullPath.indexOf('.git') === 0)
|
|
66
|
+
return;
|
|
67
|
+
/* c8 ignore stop */
|
|
68
|
+
if (exclude) {
|
|
69
|
+
for (let i = 0; i < exclude.length; i++) {
|
|
70
|
+
/* c8 ignore next */
|
|
71
|
+
if (exclude[i].test(fullPath))
|
|
61
72
|
return;
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
/* c8 ignore stop */
|
|
71
|
-
}
|
|
72
|
-
if (exclude) {
|
|
73
|
-
for (let i = 0; i < exclude.length; i++) {
|
|
74
|
-
if (exclude[i].test(fullPath)) {
|
|
75
|
-
/* c8 ignore start */
|
|
76
|
-
if (!--pending)
|
|
77
|
-
callback === null || callback === void 0 ? void 0 : callback(null, files);
|
|
78
|
-
return;
|
|
79
|
-
/* c8 ignore stop */
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
if (filter.test(fullPath)) {
|
|
84
|
-
files.push(fullPath);
|
|
85
|
-
/* c8 ignore start */
|
|
86
|
-
if (!--pending)
|
|
87
|
-
callback === null || callback === void 0 ? void 0 : callback(null, files);
|
|
88
|
-
return;
|
|
89
|
-
/* c8 ignore stop */
|
|
90
|
-
}
|
|
91
|
-
if (stat.isDirectory()) {
|
|
92
|
-
getAllFiles(fullPath, files, configs, (err) => {
|
|
93
|
-
/* c8 ignore start */
|
|
94
|
-
if (err) {
|
|
95
|
-
if (!--pending)
|
|
96
|
-
callback === null || callback === void 0 ? void 0 : callback(err, files);
|
|
97
|
-
return;
|
|
98
|
-
}
|
|
99
|
-
/* c8 ignore stop */
|
|
100
|
-
if (!--pending)
|
|
101
|
-
callback === null || callback === void 0 ? void 0 : callback(null, files);
|
|
102
|
-
});
|
|
103
|
-
/* c8 ignore next */
|
|
104
|
-
}
|
|
105
|
-
else if (!--pending)
|
|
106
|
-
callback === null || callback === void 0 ? void 0 : callback(null, files);
|
|
107
|
-
});
|
|
108
|
-
});
|
|
109
|
-
});
|
|
110
|
-
};
|
|
111
|
-
const listFiles = (targetDir, configs) => new Promise((resolve, reject) => {
|
|
112
|
-
getAllFiles((0, exports.sanitizePath)(targetDir), [], configs, (err, result) => {
|
|
113
|
-
if (err)
|
|
114
|
-
return reject(err);
|
|
115
|
-
resolve(result);
|
|
116
|
-
});
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
if (filter.test(fullPath))
|
|
76
|
+
return files.push(fullPath);
|
|
77
|
+
if (stat.isDirectory())
|
|
78
|
+
yield (0, exports.getAllFiles)(fullPath, files, configs);
|
|
79
|
+
})));
|
|
80
|
+
return files;
|
|
117
81
|
});
|
|
82
|
+
exports.getAllFiles = getAllFiles;
|
|
83
|
+
/* c8 ignore start */
|
|
84
|
+
const listFiles = (targetDir, configs) => __awaiter(void 0, void 0, void 0, function* () { return yield (0, exports.getAllFiles)((0, exports.sanitizePath)(targetDir), [], configs); });
|
|
118
85
|
exports.listFiles = listFiles;
|
|
86
|
+
/* c8 ignore stop */
|
package/lib/modules/test.js
CHANGED
|
@@ -13,6 +13,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
13
13
|
};
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.test = void 0;
|
|
16
|
+
/* c8 ignore next */
|
|
16
17
|
const node_process_1 = __importDefault(require("process"));
|
|
17
18
|
/* c8 ignore next */
|
|
18
19
|
const each_js_1 = require("../configs/each.js");
|
|
@@ -22,6 +23,7 @@ const format_js_1 = require("../helpers/format.js");
|
|
|
22
23
|
const logs_js_1 = require("../helpers/logs.js");
|
|
23
24
|
function test(...args) {
|
|
24
25
|
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
/* c8 ignore stop */
|
|
25
27
|
let message;
|
|
26
28
|
let cb;
|
|
27
29
|
if (typeof each_js_1.each.before.cb === 'function' && each_js_1.each.before.test) {
|
package/lib/polyfills/fs.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
/// <reference types="node" />
|
|
2
2
|
/// <reference types="node" />
|
|
3
3
|
import { type Dirent, type Stats } from 'node:fs';
|
|
4
|
-
export declare
|
|
4
|
+
export declare function readdir(path: string): Promise<string[]>;
|
|
5
|
+
export declare function readdir(path: string, options: {
|
|
5
6
|
withFileTypes: true;
|
|
6
|
-
})
|
|
7
|
+
}): Promise<Dirent[]>;
|
|
7
8
|
export declare const stat: (path: string) => Promise<Stats>;
|
|
8
9
|
export declare const readFile: (path: string, encoding?: BufferEncoding) => Promise<string>;
|
package/lib/polyfills/fs.js
CHANGED
|
@@ -3,22 +3,30 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.readFile = exports.stat = exports.readdir = void 0;
|
|
5
5
|
const node_fs_1 = require("fs");
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
if (
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
6
|
+
function readdir(path, options) {
|
|
7
|
+
return new Promise((resolve, reject) => {
|
|
8
|
+
if (options === null || options === void 0 ? void 0 : options.withFileTypes) {
|
|
9
|
+
(0, node_fs_1.readdir)(path, { withFileTypes: true }, (err, entries) => {
|
|
10
|
+
if (err)
|
|
11
|
+
return reject(err);
|
|
12
|
+
resolve(entries);
|
|
13
|
+
});
|
|
14
|
+
return;
|
|
15
|
+
}
|
|
16
|
+
(0, node_fs_1.readdir)(path, (err, files) => {
|
|
17
|
+
if (err)
|
|
18
|
+
return reject(err);
|
|
19
|
+
resolve(files);
|
|
20
|
+
});
|
|
12
21
|
});
|
|
13
|
-
}
|
|
22
|
+
}
|
|
14
23
|
exports.readdir = readdir;
|
|
15
24
|
const stat = (path) => {
|
|
16
25
|
return new Promise((resolve, reject) => {
|
|
17
26
|
(0, node_fs_1.stat)(path, (err, stats) => {
|
|
18
27
|
if (err)
|
|
19
|
-
reject(err);
|
|
20
|
-
|
|
21
|
-
resolve(stats);
|
|
28
|
+
return reject(err);
|
|
29
|
+
resolve(stats);
|
|
22
30
|
});
|
|
23
31
|
});
|
|
24
32
|
};
|
|
@@ -26,9 +34,8 @@ exports.stat = stat;
|
|
|
26
34
|
const readFile = (path, encoding = 'utf-8') => new Promise((resolve, reject) => {
|
|
27
35
|
(0, node_fs_1.readFile)(path, encoding, (err, data) => {
|
|
28
36
|
if (err)
|
|
29
|
-
reject(err);
|
|
30
|
-
|
|
31
|
-
resolve(data);
|
|
37
|
+
return reject(err);
|
|
38
|
+
resolve(data);
|
|
32
39
|
});
|
|
33
40
|
});
|
|
34
41
|
exports.readFile = readFile;
|
package/lib/polyfills/object.js
CHANGED
|
@@ -14,7 +14,8 @@ const entries = (obj) => {
|
|
|
14
14
|
};
|
|
15
15
|
exports.entries = entries;
|
|
16
16
|
const fromEntries = (entries) => {
|
|
17
|
-
|
|
17
|
+
const mappedEntries = entries instanceof Map ? Array.from(entries) : entries;
|
|
18
|
+
return mappedEntries.reduce((acc, [key, value]) => {
|
|
18
19
|
acc[key] = value;
|
|
19
20
|
return acc;
|
|
20
21
|
}, {});
|
|
@@ -42,7 +42,7 @@ const runTests = (dir, configs) => __awaiter(void 0, void 0, void 0, function* (
|
|
|
42
42
|
let passed = true;
|
|
43
43
|
if (showLogs) {
|
|
44
44
|
(0, hr_js_1.hr)();
|
|
45
|
-
(0, logs_js_1.write)(`${format_js_1.format.bold(isFile ? 'File:' : 'Directory:')} ${format_js_1.format.underline(
|
|
45
|
+
(0, logs_js_1.write)(`${format_js_1.format.bold(isFile ? 'File:' : 'Directory:')} ${format_js_1.format.underline(`.${node_path_1.sep}${currentDir}`)}${node_os_1.EOL}`);
|
|
46
46
|
}
|
|
47
47
|
for (let i = 0; i < files.length; i++) {
|
|
48
48
|
const filePath = files[i];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "poku",
|
|
3
|
-
"version": "1.17.
|
|
3
|
+
"version": "1.17.1",
|
|
4
4
|
"description": "🐷 Poku makes testing easy for Node.js, Bun, Deno and you at the same time.",
|
|
5
5
|
"main": "./lib/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -15,8 +15,8 @@
|
|
|
15
15
|
"test:deno:parallel": "tsx src/bin/index.ts --platform=\"deno\" --deno-allow=\"all\" --deno-cjs --parallel --include=\"ci/test/unit,ci/test/integration,ci/test/e2e\"",
|
|
16
16
|
"test:c8:sequential": "c8 tsx src/bin/index.ts --include=\"test/unit,test/integration,test/e2e\"",
|
|
17
17
|
"test:c8:parallel": "c8 tsx src/bin/index.ts --parallel --include=\"test/unit,test/integration,test/e2e\"",
|
|
18
|
-
"test:c8:sequential:options": "c8 tsx src/bin/index.ts --fast-fail --debug --exclude=\".bak\" --kill-port=\"4000\" --kill-range=\"4000-4001\" --include=\"test/unit,test/integration,test/e2e\"",
|
|
19
|
-
"test:c8:parallel:options": "c8 tsx src/bin/index.ts --parallel --concurrency=\"4\" --fast-fail --debug --exclude=\".bak\" --kill-port=\"4000\" --kill-range=\"4000-4001\" --include=\"test/unit,test/integration,test/e2e\"",
|
|
18
|
+
"test:c8:sequential:options": "c8 tsx src/bin/index.ts --platform=\"node\" --fast-fail --debug --exclude=\".bak\" --kill-port=\"4000\" --kill-range=\"4000-4001\" --include=\"test/unit,test/integration,test/e2e\" --filter=\".test.|.spec.\"",
|
|
19
|
+
"test:c8:parallel:options": "c8 tsx src/bin/index.ts --parallel --concurrency=\"4\" --platform=\"node\" --fast-fail --debug --exclude=\".bak\" --kill-port=\"4000\" --kill-range=\"4000-4001\" --include=\"test/unit,test/integration,test/e2e\" --filter=\".test.|.spec.\"",
|
|
20
20
|
"test:ci": "tsx ./test/ci.test.ts",
|
|
21
21
|
"test:ci:node": "FILTER='node-' npm run test:ci",
|
|
22
22
|
"test:ci:bun": "FILTER='bun-' npm run test:ci",
|
|
@@ -137,7 +137,7 @@
|
|
|
137
137
|
"packages-update": "^2.0.0",
|
|
138
138
|
"prettier": "^3.3.2",
|
|
139
139
|
"shx": "^0.3.4",
|
|
140
|
-
"tsx": "4.15.
|
|
140
|
+
"tsx": "4.15.6",
|
|
141
141
|
"typescript": "^5.4.5"
|
|
142
142
|
}
|
|
143
143
|
}
|