@rstest/core 0.9.0 → 0.9.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/dist/1157.js CHANGED
@@ -1441,7 +1441,7 @@ const globalApis = [
1441
1441
  'onTestFailed'
1442
1442
  ];
1443
1443
  const TS_CONFIG_FILE = 'tsconfig.json';
1444
- const external_node_path_ = __webpack_require__("node:path");
1444
+ const external_node_path_ = __webpack_require__("path");
1445
1445
  const external_node_fs_ = __webpack_require__("node:fs");
1446
1446
  var __require = /* @__PURE__ */ createRequire(import.meta.url);
1447
1447
  function cleanPath(path) {
package/dist/1294.js CHANGED
@@ -4821,7 +4821,7 @@ __webpack_require__.add({
4821
4821
  },
4822
4822
  "../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js" (module, __unused_rspack_exports, __webpack_require__) {
4823
4823
  const os = __webpack_require__("node:os");
4824
- const tty = __webpack_require__("tty");
4824
+ const tty = __webpack_require__("node:tty");
4825
4825
  const hasFlag = __webpack_require__("../../node_modules/.pnpm/has-flag@4.0.0/node_modules/has-flag/index.js");
4826
4826
  const { env } = process;
4827
4827
  let forceColor;
package/dist/3160.js CHANGED
@@ -4,6 +4,7 @@ import * as __rspack_external_node_fs_5ea92f0c from "node:fs";
4
4
  import * as __rspack_external_node_os_74b4b876 from "node:os";
5
5
  import * as __rspack_external_node_path_c5b9b54f from "node:path";
6
6
  import * as __rspack_external_node_tty_c64aab7e from "node:tty";
7
+ import * as __rspack_external_node_util_1b29d436 from "node:util";
7
8
  import { __webpack_require__ } from "./rslib-runtime.js";
8
9
  import node_process, { stdin, stdout } from "node:process";
9
10
  __webpack_require__.add({
@@ -79,15 +80,27 @@ __webpack_require__.add({
79
80
  "node:os" (module) {
80
81
  module.exports = __rspack_external_node_os_74b4b876;
81
82
  },
82
- "node:path" (module) {
83
+ path (module) {
83
84
  module.exports = __rspack_external_node_path_c5b9b54f;
84
85
  },
85
- tty (module) {
86
+ "node:tty" (module) {
86
87
  module.exports = __rspack_external_node_tty_c64aab7e;
88
+ },
89
+ "node:util" (module) {
90
+ module.exports = __rspack_external_node_util_1b29d436;
87
91
  }
88
92
  });
93
+ const external_node_util_ = __webpack_require__("node:util");
89
94
  const external_node_os_ = __webpack_require__("node:os");
90
- const external_node_tty_ = __webpack_require__("tty");
95
+ const external_node_tty_ = __webpack_require__("node:tty");
96
+ const createStyler = (style)=>(text)=>(0, external_node_util_.styleText)(style, String(text));
97
+ const bold = createStyler('bold');
98
+ const red = createStyler('red');
99
+ const green = createStyler('green');
100
+ const yellow = createStyler('yellow');
101
+ const magenta = createStyler('magenta');
102
+ const cyan = createStyler('cyan');
103
+ const gray = createStyler('gray');
91
104
  function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : node_process.argv) {
92
105
  const prefix = flag.startsWith('-') ? '' : 1 === flag.length ? '-' : '--';
93
106
  const position = argv.indexOf(prefix + flag);
@@ -194,24 +207,6 @@ let errorStackRegExp = /at [^\r\n]{0,200}:\d+:\d+[\s\)]*$/;
194
207
  let anonymousErrorStackRegExp = /at [^\r\n]{0,200}\(<anonymous>\)$/;
195
208
  let indexErrorStackRegExp = /at [^\r\n]{0,200}\(index\s\d+\)$/;
196
209
  let isErrorStackMessage = (message)=>errorStackRegExp.test(message) || anonymousErrorStackRegExp.test(message) || indexErrorStackRegExp.test(message);
197
- let formatter = (open, close, replace = open)=>colorLevel >= 2 ? (input)=>{
198
- let string = '' + input;
199
- let index = string.indexOf(close, open.length);
200
- return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
201
- } : String;
202
- let replaceClose = (string, close, replace, index)=>{
203
- let start = string.substring(0, index) + replace;
204
- let end = string.substring(index + close.length);
205
- let nextIndex = end.indexOf(close);
206
- return ~nextIndex ? start + replaceClose(end, close, replace, nextIndex) : start + end;
207
- };
208
- const bold = formatter('\x1b[1m', '\x1b[22m', '\x1b[22m\x1b[1m');
209
- const red = formatter('\x1b[31m', '\x1b[39m');
210
- const green = formatter('\x1b[32m', '\x1b[39m');
211
- const yellow = formatter('\x1b[33m', '\x1b[39m');
212
- const magenta = formatter('\x1b[35m', '\x1b[39m');
213
- const cyan = formatter('\x1b[36m', '\x1b[39m');
214
- const gray = formatter('\x1b[90m', '\x1b[39m');
215
210
  let startColor = [
216
211
  189,
217
212
  255,
package/dist/487.js CHANGED
@@ -35,7 +35,7 @@ __webpack_require__.add({
35
35
  "../../node_modules/.pnpm/source-map-support@0.5.21/node_modules/source-map-support/source-map-support.js" (module, exports, __webpack_require__) {
36
36
  module = __webpack_require__.nmd(module);
37
37
  var SourceMapConsumer = __webpack_require__("../../node_modules/.pnpm/source-map@0.6.1/node_modules/source-map/source-map.js").SourceMapConsumer;
38
- var path = __webpack_require__("node:path");
38
+ var path = __webpack_require__("path");
39
39
  var fs;
40
40
  try {
41
41
  fs = __webpack_require__("node:fs");