@bigbinary/neeto-playwright-reporter 1.5.4 → 1.5.6
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/index.cjs.js +58 -77
- package/index.cjs.js.map +1 -1
- package/index.d.ts +1 -0
- package/index.js +9 -10
- package/index.js.map +1 -1
- package/package.json +5 -5
package/index.d.ts
CHANGED
|
@@ -16,6 +16,7 @@ declare class NeetoPlaywrightReporter implements Reporter {
|
|
|
16
16
|
heartbeatInterval: NodeJS.Timeout | null;
|
|
17
17
|
rootDir: string;
|
|
18
18
|
progressBars: (Bar | void)[];
|
|
19
|
+
startedAttempts: Set<string>;
|
|
19
20
|
constructor(options: ReporterOptionParams);
|
|
20
21
|
onBegin: (config: FullConfig, rootSuite: Suite) => Promise<void>;
|
|
21
22
|
onTestBegin: (test: TestCase, result: TestResult) => Promise<void>;
|
package/index.js
CHANGED
|
@@ -1492,10 +1492,7 @@ function _iterableToArrayLimit(r, l) {
|
|
|
1492
1492
|
f = !0,
|
|
1493
1493
|
o = !1;
|
|
1494
1494
|
try {
|
|
1495
|
-
if (i = (t = t.call(r)).next, 0 === l)
|
|
1496
|
-
if (Object(t) !== t) return;
|
|
1497
|
-
f = !1;
|
|
1498
|
-
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
1495
|
+
if (i = (t = t.call(r)).next, 0 === l) ; else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
1499
1496
|
} catch (r) {
|
|
1500
1497
|
o = !0, n = r;
|
|
1501
1498
|
} finally {
|
|
@@ -1552,11 +1549,11 @@ function _toPrimitive(input, hint) {
|
|
|
1552
1549
|
if (_typeof(input) !== "object" || input === null) return input;
|
|
1553
1550
|
var prim = input[Symbol.toPrimitive];
|
|
1554
1551
|
if (prim !== undefined) {
|
|
1555
|
-
var res = prim.call(input, hint
|
|
1552
|
+
var res = prim.call(input, hint);
|
|
1556
1553
|
if (_typeof(res) !== "object") return res;
|
|
1557
1554
|
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
1558
1555
|
}
|
|
1559
|
-
return (
|
|
1556
|
+
return (String )(input);
|
|
1560
1557
|
}
|
|
1561
1558
|
|
|
1562
1559
|
function _toPropertyKey(arg) {
|
|
@@ -1575,7 +1572,6 @@ function _defineProperties(target, props) {
|
|
|
1575
1572
|
}
|
|
1576
1573
|
function _createClass(Constructor, protoProps, staticProps) {
|
|
1577
1574
|
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
1578
|
-
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
1579
1575
|
Object.defineProperty(Constructor, "prototype", {
|
|
1580
1576
|
writable: false
|
|
1581
1577
|
});
|
|
@@ -15884,8 +15880,8 @@ const origin = hasBrowserEnv && window.location.href || 'http://localhost';
|
|
|
15884
15880
|
var utils = /*#__PURE__*/Object.freeze({
|
|
15885
15881
|
__proto__: null,
|
|
15886
15882
|
hasBrowserEnv: hasBrowserEnv,
|
|
15887
|
-
hasStandardBrowserWebWorkerEnv: hasStandardBrowserWebWorkerEnv,
|
|
15888
15883
|
hasStandardBrowserEnv: hasStandardBrowserEnv,
|
|
15884
|
+
hasStandardBrowserWebWorkerEnv: hasStandardBrowserWebWorkerEnv,
|
|
15889
15885
|
navigator: _navigator,
|
|
15890
15886
|
origin: origin
|
|
15891
15887
|
});
|
|
@@ -20247,7 +20243,7 @@ const composeSignals = (signals, timeout) => {
|
|
|
20247
20243
|
const streamChunk = function* (chunk, chunkSize) {
|
|
20248
20244
|
let len = chunk.byteLength;
|
|
20249
20245
|
|
|
20250
|
-
if (
|
|
20246
|
+
if (len < chunkSize) {
|
|
20251
20247
|
yield chunk;
|
|
20252
20248
|
return;
|
|
20253
20249
|
}
|
|
@@ -21521,6 +21517,7 @@ const onTestBegin = async (self, test, { retry }) => {
|
|
|
21521
21517
|
[historyId]: { [attemptIndex]: attemptId },
|
|
21522
21518
|
});
|
|
21523
21519
|
}
|
|
21520
|
+
self.startedAttempts.add(joinHyphenCase(historyId, attemptIndex));
|
|
21524
21521
|
}
|
|
21525
21522
|
catch (error) {
|
|
21526
21523
|
consoleLogFormatted.error(error.message);
|
|
@@ -22906,6 +22903,7 @@ const onTestEnd = async (self, testCase, { status, duration, errors, error, retr
|
|
|
22906
22903
|
completedAt: completedAt.toString(),
|
|
22907
22904
|
errorSnippet: error && generateErrorReport(error),
|
|
22908
22905
|
};
|
|
22906
|
+
await waitUntilCondition(() => self.startedAttempts.has(joinHyphenCase(historyId, attemptIndex)));
|
|
22909
22907
|
consoleLogFormatted.underline(title);
|
|
22910
22908
|
const files = attachments
|
|
22911
22909
|
.map(({ name, path, body, contentType }) => {
|
|
@@ -22925,7 +22923,6 @@ const onTestEnd = async (self, testCase, { status, duration, errors, error, retr
|
|
|
22925
22923
|
return uploadToS3(files[index].file, directUpload, `${title} - ${(_b = files[index]) === null || _b === void 0 ? void 0 : _b.name}`);
|
|
22926
22924
|
}));
|
|
22927
22925
|
self.progressBars.push(...bars);
|
|
22928
|
-
await waitUntilCondition(() => self.attempts[historyId][attemptIndex]);
|
|
22929
22926
|
const reportToNeetoPlaydash = attemptsApi.update(ciBuildId, historyId, self.attempts[historyId][attemptIndex], testResult);
|
|
22930
22927
|
self.testResultCalls.push(reportToNeetoPlaydash);
|
|
22931
22928
|
await reportToNeetoPlaydash;
|
|
@@ -22938,6 +22935,7 @@ const onTestEnd = async (self, testCase, { status, duration, errors, error, retr
|
|
|
22938
22935
|
}
|
|
22939
22936
|
finally {
|
|
22940
22937
|
self.unreportedAttemptCount--;
|
|
22938
|
+
self.startedAttempts.delete(joinHyphenCase(historyId, attemptIndex));
|
|
22941
22939
|
}
|
|
22942
22940
|
};
|
|
22943
22941
|
|
|
@@ -23006,6 +23004,7 @@ class NeetoPlaywrightReporter {
|
|
|
23006
23004
|
this.rootDir = "";
|
|
23007
23005
|
this.currentShard = 0;
|
|
23008
23006
|
this.progressBars = [];
|
|
23007
|
+
this.startedAttempts = new Set();
|
|
23009
23008
|
initialize(this, options);
|
|
23010
23009
|
}
|
|
23011
23010
|
}
|