monocart-reporter 2.9.22 → 2.9.23
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 +1 -1
- package/lib/generate-data.js +3 -1
- package/lib/generate-report.js +1 -5
- package/lib/merge-data.js +3 -1
- package/lib/packages/monocart-reporter-assets.js +1 -1
- package/lib/packages/monocart-reporter-vendor.js +27 -27
- package/lib/utils/util.js +1 -1
- package/package.json +89 -89
package/README.md
CHANGED
|
@@ -1128,7 +1128,7 @@ The `onEnd` function will be executed after report generated. Arguments:
|
|
|
1128
1128
|
- `reportData` all report data, properties:
|
|
1129
1129
|
- `name` (String) report name
|
|
1130
1130
|
- `date` (Number) start date in milliseconds
|
|
1131
|
-
- `dateH` (String) human-readable date
|
|
1131
|
+
- `dateH` (String) human-readable date
|
|
1132
1132
|
- `duration` (Number) test duration in milliseconds
|
|
1133
1133
|
- `durationH` (String) human-readable duration
|
|
1134
1134
|
- `summary` (Object) test summary, includes `tests`, `suites`, `steps`, etc.
|
package/lib/generate-data.js
CHANGED
|
@@ -133,7 +133,9 @@ const generateData = async (results) => {
|
|
|
133
133
|
|
|
134
134
|
// let start timestamp as date
|
|
135
135
|
const date = system.timestampStart;
|
|
136
|
-
|
|
136
|
+
|
|
137
|
+
const timezoneDate = Util.addTimezoneOffset(date, timezoneOffset);
|
|
138
|
+
const dateH = Util.dateFormat(timezoneDate, locale);
|
|
137
139
|
|
|
138
140
|
// end timestamp for duration
|
|
139
141
|
system.timestampEnd = timestamp;
|
package/lib/generate-report.js
CHANGED
|
@@ -204,18 +204,14 @@ const showTestResults = (reportData) => {
|
|
|
204
204
|
|
|
205
205
|
// for shards
|
|
206
206
|
const system = Array.isArray(reportData.system) ? reportData.system[0] : reportData.system;
|
|
207
|
-
|
|
208
207
|
// console.log(Util.dateFormat(reportData.date, reportData.locale));
|
|
209
208
|
|
|
210
|
-
const timezoneDate = Util.addTimezoneOffset(reportData.date, reportData.timezoneOffset);
|
|
211
|
-
// console.log(Util.dateFormat(timezoneDate, reportData.locale));
|
|
212
|
-
|
|
213
209
|
rows = rows.concat([{
|
|
214
210
|
name: 'Playwright',
|
|
215
211
|
value: `v${system.playwright}`
|
|
216
212
|
}, {
|
|
217
213
|
name: 'Date',
|
|
218
|
-
value:
|
|
214
|
+
value: reportData.dateH
|
|
219
215
|
}, {
|
|
220
216
|
name: 'Duration',
|
|
221
217
|
value: Util.TF(reportData.duration)
|
package/lib/merge-data.js
CHANGED
|
@@ -336,7 +336,9 @@ const mergeDataList = async (dataList, options) => {
|
|
|
336
336
|
const reportLogo = options.logo || mergedData.logo;
|
|
337
337
|
|
|
338
338
|
const date = Math.min.apply(null, startDates);
|
|
339
|
-
|
|
339
|
+
|
|
340
|
+
const timezoneDate = Util.addTimezoneOffset(date, mergedData.timezoneOffset);
|
|
341
|
+
const dateH = Util.dateFormat(timezoneDate, mergedData.locale);
|
|
340
342
|
|
|
341
343
|
const duration = Util.getDuration(dateRanges, options.durationStrategy);
|
|
342
344
|
const durationH = Util.TF(duration);
|