html-reporter 8.2.0 → 8.3.0
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/CHANGELOG.md +10 -0
- package/README.md +44 -7
- package/lib/cli-commands/index.js +2 -1
- package/lib/cli-commands/remove-unused-screens/index.js +194 -0
- package/lib/cli-commands/remove-unused-screens/utils.js +159 -0
- package/lib/common-utils.js +52 -52
- package/lib/config/index.js +1 -1
- package/lib/constants/database.js +24 -4
- package/lib/db-utils/client.js +109 -0
- package/lib/db-utils/common.js +76 -0
- package/lib/db-utils/server.js +124 -0
- package/lib/gui/index.js +2 -1
- package/lib/gui/server.js +2 -1
- package/lib/gui/tool-runner/index.js +7 -7
- package/lib/gui/tool-runner/utils.js +7 -25
- package/lib/plugin-adapter.js +1 -1
- package/lib/plugin-api.js +17 -3
- package/lib/report-builder/static.js +1 -1
- package/lib/server-utils.js +1 -4
- package/lib/sqlite-adapter.js +3 -4
- package/lib/static/components/section/body/meta-info.js +1 -1
- package/lib/static/components/state/screenshot.js +1 -1
- package/lib/static/gui.min.js +19 -19
- package/lib/static/modules/actions.js +2 -3
- package/lib/static/modules/reducers/db.js +1 -1
- package/lib/static/modules/utils.js +0 -12
- package/lib/static/report.min.js +20 -20
- package/lib/test-adapter.js +2 -1
- package/lib/tests-tree-builder/static.js +13 -13
- package/package.json +6 -1
- package/lib/constants/file-names.js +0 -6
- package/lib/static/data.js +0 -611
- package/lib/static/databaseUrls.json +0 -1
- package/lib/static/modules/database-utils.js +0 -36
- package/lib/static/modules/sqlite.js +0 -152
- package/sqlite.db +0 -0
package/lib/test-adapter.js
CHANGED
|
@@ -13,6 +13,7 @@ const {getCommandsHistory} = require('./history-utils');
|
|
|
13
13
|
const {SUCCESS, FAIL, ERROR, UPDATED} = require('./constants/test-statuses');
|
|
14
14
|
const {ERROR_DETAILS_PATH} = require('./constants/paths');
|
|
15
15
|
const utils = require('./server-utils');
|
|
16
|
+
const {logger} = require('./common-utils');
|
|
16
17
|
|
|
17
18
|
const globalCacheAllImages = new Map();
|
|
18
19
|
|
|
@@ -125,7 +126,7 @@ module.exports = class TestAdapter {
|
|
|
125
126
|
|
|
126
127
|
async saveBase64Screenshot(reportPath) {
|
|
127
128
|
if (!this.screenshot.base64) {
|
|
128
|
-
|
|
129
|
+
logger.warn('Cannot save screenshot on reject');
|
|
129
130
|
|
|
130
131
|
return Promise.resolve();
|
|
131
132
|
}
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
const _ = require('lodash');
|
|
4
4
|
const BaseTestsTreeBuilder = require('./base');
|
|
5
|
-
const {dbColumnIndexes} = require('../common-utils');
|
|
6
5
|
const testStatus = require('../constants/test-statuses');
|
|
7
6
|
const {versions: browserVersions} = require('../constants/browser');
|
|
7
|
+
const {DB_COLUMN_INDEXES} = require('../constants/database');
|
|
8
8
|
|
|
9
9
|
module.exports = class StaticTestsTreeBuilder extends BaseTestsTreeBuilder {
|
|
10
10
|
constructor() {
|
|
@@ -25,8 +25,8 @@ module.exports = class StaticTestsTreeBuilder extends BaseTestsTreeBuilder {
|
|
|
25
25
|
const browsers = {};
|
|
26
26
|
|
|
27
27
|
for (const row of rows) {
|
|
28
|
-
const testPath = JSON.parse(row[
|
|
29
|
-
const browserName = row[
|
|
28
|
+
const testPath = JSON.parse(row[DB_COLUMN_INDEXES.suitePath]);
|
|
29
|
+
const browserName = row[DB_COLUMN_INDEXES.name];
|
|
30
30
|
|
|
31
31
|
const testId = this._buildId(testPath);
|
|
32
32
|
const browserId = this._buildId(testId, browserName);
|
|
@@ -151,16 +151,16 @@ function initStats() {
|
|
|
151
151
|
|
|
152
152
|
function mkTestResult(row, data = {}) {
|
|
153
153
|
return {
|
|
154
|
-
description: row[
|
|
155
|
-
imagesInfo: JSON.parse(row[
|
|
156
|
-
metaInfo: JSON.parse(row[
|
|
157
|
-
multipleTabs: Boolean(row[
|
|
158
|
-
name: row[
|
|
159
|
-
screenshot: Boolean(row[
|
|
160
|
-
status: row[
|
|
161
|
-
suiteUrl: row[
|
|
162
|
-
skipReason: row[
|
|
163
|
-
error: JSON.parse(row[
|
|
154
|
+
description: row[DB_COLUMN_INDEXES.description],
|
|
155
|
+
imagesInfo: JSON.parse(row[DB_COLUMN_INDEXES.imagesInfo]),
|
|
156
|
+
metaInfo: JSON.parse(row[DB_COLUMN_INDEXES.metaInfo]),
|
|
157
|
+
multipleTabs: Boolean(row[DB_COLUMN_INDEXES.multipleTabs]),
|
|
158
|
+
name: row[DB_COLUMN_INDEXES.name],
|
|
159
|
+
screenshot: Boolean(row[DB_COLUMN_INDEXES.screenshot]),
|
|
160
|
+
status: row[DB_COLUMN_INDEXES.status],
|
|
161
|
+
suiteUrl: row[DB_COLUMN_INDEXES.suiteUrl],
|
|
162
|
+
skipReason: row[DB_COLUMN_INDEXES.skipReason],
|
|
163
|
+
error: JSON.parse(row[DB_COLUMN_INDEXES.error]),
|
|
164
164
|
...data
|
|
165
165
|
};
|
|
166
166
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "html-reporter",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.3.0",
|
|
4
4
|
"description": "Plugin for hermione which is intended to aggregate the results of tests running into html report",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"coverage": "nyc npm run test-unit",
|
|
@@ -51,16 +51,20 @@
|
|
|
51
51
|
"chalk": "^1.1.3",
|
|
52
52
|
"debug": "^4.1.1",
|
|
53
53
|
"express": "^4.16.2",
|
|
54
|
+
"filesize": "^8.0.6",
|
|
54
55
|
"fs-extra": "^7.0.1",
|
|
55
56
|
"gemini-configparser": "^1.0.0",
|
|
56
57
|
"gemini-core": "^6.3.2",
|
|
57
58
|
"http-codes": "1.0.0",
|
|
58
59
|
"immer": "^7.0.7",
|
|
60
|
+
"inquirer": "^8.2.0",
|
|
59
61
|
"json-stringify-safe": "^5.0.1",
|
|
60
62
|
"lodash": "^4.17.4",
|
|
61
63
|
"looks-same": "^7.1.1",
|
|
64
|
+
"micromatch": "^4.0.4",
|
|
62
65
|
"nested-error-stacks": "^2.1.0",
|
|
63
66
|
"opener": "^1.4.3",
|
|
67
|
+
"ora": "^5.4.1",
|
|
64
68
|
"p-queue": "^5.0.0",
|
|
65
69
|
"qs": "^6.9.1",
|
|
66
70
|
"react-hotkeys": "^2.0.0",
|
|
@@ -79,6 +83,7 @@
|
|
|
79
83
|
"web-vitals": "^1.1.2"
|
|
80
84
|
},
|
|
81
85
|
"devDependencies": {
|
|
86
|
+
"@gemini-testing/commander": "^2.15.3",
|
|
82
87
|
"app-module-path": "^2.2.0",
|
|
83
88
|
"babel-core": "^6.26.0",
|
|
84
89
|
"babel-eslint": "^8.0.1",
|