@allurereport/plugin-allure2 3.0.0-beta.12 → 3.0.0-beta.13
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/writer.js +5 -4
- package/package.json +5 -5
package/dist/writer.js
CHANGED
|
@@ -6,6 +6,7 @@ var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (
|
|
|
6
6
|
var _InMemoryReportDataWriter_data;
|
|
7
7
|
import { mkdir, writeFile } from "node:fs/promises";
|
|
8
8
|
import { join, resolve } from "node:path";
|
|
9
|
+
import { join as joinPosix } from "node:path/posix";
|
|
9
10
|
export class FileSystemReportDataWriter {
|
|
10
11
|
constructor(output) {
|
|
11
12
|
this.output = output;
|
|
@@ -67,19 +68,19 @@ export class ReportFileDataWriter {
|
|
|
67
68
|
this.reportFiles = reportFiles;
|
|
68
69
|
}
|
|
69
70
|
async writeData(fileName, data) {
|
|
70
|
-
await this.reportFiles.addFile(
|
|
71
|
+
await this.reportFiles.addFile(joinPosix("data", fileName), Buffer.from(JSON.stringify(data), "utf-8"));
|
|
71
72
|
}
|
|
72
73
|
async writeWidget(fileName, data) {
|
|
73
|
-
await this.reportFiles.addFile(
|
|
74
|
+
await this.reportFiles.addFile(joinPosix("widgets", fileName), Buffer.from(JSON.stringify(data), "utf-8"));
|
|
74
75
|
}
|
|
75
76
|
async writeAttachment(source, file) {
|
|
76
77
|
const contentBuffer = await file.asBuffer();
|
|
77
78
|
if (!contentBuffer) {
|
|
78
79
|
return;
|
|
79
80
|
}
|
|
80
|
-
await this.reportFiles.addFile(
|
|
81
|
+
await this.reportFiles.addFile(joinPosix("data", "attachments", source), contentBuffer);
|
|
81
82
|
}
|
|
82
83
|
async writeTestCase(test) {
|
|
83
|
-
await this.reportFiles.addFile(
|
|
84
|
+
await this.reportFiles.addFile(joinPosix("data", "test-cases", `${test.uid}.json`), Buffer.from(JSON.stringify(test), "utf8"));
|
|
84
85
|
}
|
|
85
86
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@allurereport/plugin-allure2",
|
|
3
|
-
"version": "3.0.0-beta.
|
|
3
|
+
"version": "3.0.0-beta.13",
|
|
4
4
|
"description": "The classic version of Allure HTML report",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"allure",
|
|
@@ -30,10 +30,10 @@
|
|
|
30
30
|
"test": "rimraf ./out && vitest run"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@allurereport/core-api": "3.0.0-beta.
|
|
34
|
-
"@allurereport/plugin-api": "3.0.0-beta.
|
|
35
|
-
"@allurereport/web-allure2": "3.0.0-beta.
|
|
36
|
-
"@allurereport/web-commons": "3.0.0-beta.
|
|
33
|
+
"@allurereport/core-api": "3.0.0-beta.13",
|
|
34
|
+
"@allurereport/plugin-api": "3.0.0-beta.13",
|
|
35
|
+
"@allurereport/web-allure2": "3.0.0-beta.13",
|
|
36
|
+
"@allurereport/web-commons": "3.0.0-beta.13",
|
|
37
37
|
"handlebars": "^4.7.8"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|