allure 3.4.0 → 3.5.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/dist/utils/environment.d.ts +1 -1
- package/dist/utils/environment.js +6 -1
- package/package.json +21 -21
|
@@ -6,7 +6,7 @@ type CommandEnvironmentOptions = {
|
|
|
6
6
|
};
|
|
7
7
|
export declare const environmentOption: () => string | undefined;
|
|
8
8
|
export declare const environmentNameOption: () => string | undefined;
|
|
9
|
-
export declare const resolveCommandEnvironment: (config: Pick<FullConfig, "environment" | "environments">, options: CommandEnvironmentOptions & {
|
|
9
|
+
export declare const resolveCommandEnvironment: (config: Pick<FullConfig, "environment" | "environments" | "allowedEnvironments">, options: CommandEnvironmentOptions & {
|
|
10
10
|
source?: string;
|
|
11
11
|
}) => EnvironmentIdentity | undefined;
|
|
12
12
|
export declare const normalizeCommandEnvironmentOptions: (options: CommandEnvironmentOptions) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { environmentIdentityById, environmentIdentityByName } from "@allurereport/core";
|
|
1
|
+
import { environmentIdentityById, environmentIdentityByName, validateAllowedEnvironmentId, } from "@allurereport/core";
|
|
2
2
|
import { validateEnvironmentId, validateEnvironmentName } from "@allurereport/core-api";
|
|
3
3
|
import { Option, UsageError } from "clipanion";
|
|
4
4
|
const environmentOptionDescription = "Force specific environment ID to all tests in the run. Given environment has higher priority than the one defined in the config file (default: empty string)";
|
|
@@ -38,6 +38,11 @@ export const resolveCommandEnvironment = (config, options) => {
|
|
|
38
38
|
throw new UsageError(`${source}: environment id ${JSON.stringify(identityFromId.id)} and environment name ${JSON.stringify(identityFromName.name)} resolve to different environments`);
|
|
39
39
|
}
|
|
40
40
|
const identity = identityFromId ?? identityFromName ?? configIdentity;
|
|
41
|
+
const allowedEnvironmentIds = new Set(config.allowedEnvironments ?? []);
|
|
42
|
+
const allowlistError = identity?.id !== undefined ? validateAllowedEnvironmentId(identity.id, allowedEnvironmentIds, source) : undefined;
|
|
43
|
+
if (allowlistError) {
|
|
44
|
+
throw new UsageError(allowlistError);
|
|
45
|
+
}
|
|
41
46
|
return identity;
|
|
42
47
|
};
|
|
43
48
|
export const normalizeCommandEnvironmentOptions = (options) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "allure",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.5.0",
|
|
4
4
|
"description": "Allure Commandline Tool",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"allure",
|
|
@@ -32,29 +32,29 @@
|
|
|
32
32
|
"lint:fix": "oxlint --import-plugin --fix src test features stories"
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
|
-
"@allurereport/charts-api": "3.
|
|
36
|
-
"@allurereport/ci": "3.
|
|
37
|
-
"@allurereport/core": "3.
|
|
38
|
-
"@allurereport/core-api": "3.
|
|
39
|
-
"@allurereport/directory-watcher": "3.
|
|
40
|
-
"@allurereport/plugin-allure2": "3.
|
|
41
|
-
"@allurereport/plugin-api": "3.
|
|
42
|
-
"@allurereport/plugin-awesome": "3.
|
|
43
|
-
"@allurereport/plugin-classic": "3.
|
|
44
|
-
"@allurereport/plugin-csv": "3.
|
|
45
|
-
"@allurereport/plugin-dashboard": "3.
|
|
46
|
-
"@allurereport/plugin-jira": "3.
|
|
47
|
-
"@allurereport/plugin-log": "3.
|
|
48
|
-
"@allurereport/plugin-progress": "3.
|
|
49
|
-
"@allurereport/plugin-server-reload": "3.
|
|
50
|
-
"@allurereport/plugin-slack": "3.
|
|
51
|
-
"@allurereport/reader-api": "3.
|
|
52
|
-
"@allurereport/service": "3.
|
|
53
|
-
"@allurereport/static-server": "3.
|
|
35
|
+
"@allurereport/charts-api": "3.5.0",
|
|
36
|
+
"@allurereport/ci": "3.5.0",
|
|
37
|
+
"@allurereport/core": "3.5.0",
|
|
38
|
+
"@allurereport/core-api": "3.5.0",
|
|
39
|
+
"@allurereport/directory-watcher": "3.5.0",
|
|
40
|
+
"@allurereport/plugin-allure2": "3.5.0",
|
|
41
|
+
"@allurereport/plugin-api": "3.5.0",
|
|
42
|
+
"@allurereport/plugin-awesome": "3.5.0",
|
|
43
|
+
"@allurereport/plugin-classic": "3.5.0",
|
|
44
|
+
"@allurereport/plugin-csv": "3.5.0",
|
|
45
|
+
"@allurereport/plugin-dashboard": "3.5.0",
|
|
46
|
+
"@allurereport/plugin-jira": "3.5.0",
|
|
47
|
+
"@allurereport/plugin-log": "3.5.0",
|
|
48
|
+
"@allurereport/plugin-progress": "3.5.0",
|
|
49
|
+
"@allurereport/plugin-server-reload": "3.5.0",
|
|
50
|
+
"@allurereport/plugin-slack": "3.5.0",
|
|
51
|
+
"@allurereport/reader-api": "3.5.0",
|
|
52
|
+
"@allurereport/service": "3.5.0",
|
|
53
|
+
"@allurereport/static-server": "3.5.0",
|
|
54
54
|
"adm-zip": "^0.5.16",
|
|
55
55
|
"clipanion": "^4.0.0-rc.4",
|
|
56
56
|
"glob": "^11.1.0",
|
|
57
|
-
"lodash.omit": "^4.
|
|
57
|
+
"lodash.omit": "^4.18.0",
|
|
58
58
|
"prompts": "^2.4.2",
|
|
59
59
|
"typanion": "^3.14.0",
|
|
60
60
|
"yoctocolors": "^2.1.1"
|