Skip to content

Commit

Permalink
kie-issues#866: Standardize scripts/tasks names and execution order o…
Browse files Browse the repository at this point in the history
…n KIE Tools packages (1/n) (apache#2413)
  • Loading branch information
tiagobento authored Jun 12, 2024
1 parent 5f1555b commit 80c1b67
Show file tree
Hide file tree
Showing 732 changed files with 141 additions and 141 deletions.
4 changes: 2 additions & 2 deletions .ci/jenkins/ci-jobs/Jenkinsfile.ci-build
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ pipeline {

environment {
TESTS_REPORTS_PATTERNS = 'kie-tools/packages/**/dist-tests/junit-report*.xml kie-tools/examples/**/dist-tests/junit-report*.xml kie-tools/packages/**/target/surefire-reports/TEST-*.xml kie-tools/examples/**/target/surefire-reports/TEST-*.xml'
END_TO_END_TESTS_REPORTS_PATTERNS = 'kie-tools/packages/**/dist-e2e-tests/junit-report*.xml kie-tools/examples/**/dist-e2e-tests/junit-report*.xml kie-tools/packages/**/target/failsafe-reports/TEST-*.xml kie-tools/examples/**/target/failsafe-reports/TEST-*.xml'
END_TO_END_TESTS_ARTIFACTS_PATTERNS = 'kie-tools/packages/**/dist-e2e-tests kie-tools/examples/**/dist-e2e-tests'
END_TO_END_TESTS_REPORTS_PATTERNS = 'kie-tools/packages/**/dist-tests-e2e/junit-report*.xml kie-tools/examples/**/dist-tests-e2e/junit-report*.xml kie-tools/packages/**/target/failsafe-reports/TEST-*.xml kie-tools/examples/**/target/failsafe-reports/TEST-*.xml'
END_TO_END_TESTS_ARTIFACTS_PATTERNS = 'kie-tools/packages/**/dist-tests-e2e kie-tools/examples/**/dist-tests-e2e'
BUILD_ARTIFACTS_PATTERNS = 'kie-tools/packages/**/dist kie-tools/examples/**/dist'
ENABLE_BUILDKITE = 'false'
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
**/dist-e2e-tests
**/dist-tests-e2e
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
**/dist-e2e-tests/junit-report*.xml
**/dist-e2e-tests/TESTS-*.xml
**/dist-tests-e2e/junit-report*.xml
**/dist-tests-e2e/TESTS-*.xml
**/target/failsafe-reports/TEST-*.xml
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
**/dist-dev/
**/dist-dev-webapp/
**/dist-tests/
**/dist-e2e-tests/
**/dist-tests-e2e/
**/dist-storybook/
**/e2e-tests-tmp/
**/coverage/
Expand Down
4 changes: 2 additions & 2 deletions packages/boxed-expression-component/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ pnpm start
# Compiles a production ready showcase application
pnpm build
# Run PlayWright 'BoxedExpressionEditor' tests.
pnpm test:e2e
pnpm test-e2e
# To update the PlayWright Snapshot files, used for the regression:
pnpm test:e2e:run -u
pnpm test-e2e:run -u
```

---
Expand Down
12 changes: 6 additions & 6 deletions packages/boxed-expression-component/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,19 +6,19 @@
"keywords": [],
"scripts": {
"build:dev": "rimraf dist && pnpm copy:css && tsc -p tsconfig.json",
"build:prod": "rimraf dist && pnpm copy:css && pnpm lint && tsc -p tsconfig.json && pnpm test && pnpm test:e2e",
"build:prod": "rimraf dist && pnpm copy:css && pnpm lint && tsc -p tsconfig.json && pnpm test && pnpm test-e2e",
"build:storybook": "storybook build -o dist-storybook",
"copy:css": "copyfiles -u 1 \"src/**/*.{sass,scss,css}\" dist/",
"deploy": "gh-pages -d dist-dev",
"lint": "run-script-if --bool \"$(build-env linters.run)\" --then \"kie-tools--eslint ./src\"",
"powershell": "@powershell -NoProfile -ExecutionPolicy Unrestricted -Command",
"start": "run-script-os",
"start:linux:darwin": "cross-env STORYBOOK_PORT=$(build-env boxedExpressionComponent.storybook.port) pnpm storybook-base --storybookArgs=\"dev --no-open\"",
"start:win32": "pnpm powershell \"cross-env STORYBOOK_PORT=$(build-env boxedExpressionComponent.storybook.port) pnpm storybook-base --storybookArgs='dev --no-open'",
"start:linux:darwin": "cross-env STORYBOOK_PORT=$(build-env boxedExpressionComponent.storybook.port) pnpm kie-tools--storybook --storybookArgs=\"dev --no-open\"",
"start:win32": "pnpm powershell \"cross-env STORYBOOK_PORT=$(build-env boxedExpressionComponent.storybook.port) pnpm kie-tools--storybook --storybookArgs='dev --no-open'",
"test": "run-script-if --ignore-errors \"$(build-env tests.ignoreFailures)\" --bool \"$(build-env tests.run)\" --then \"jest --silent --verbose --passWithNoTests\"",
"test:e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-e2e-tests\" \"pnpm test:e2e:run\"",
"test:e2e:open": "pnpm exec playwright show-report dist-e2e-tests/reports",
"test:e2e:run": "pnpm exec playwright test"
"test-e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-tests-e2e\" \"pnpm test-e2e:run\"",
"test-e2e:open": "pnpm exec playwright show-report dist-tests-e2e/reports",
"test-e2e:run": "pnpm exec playwright test"
},
"dependencies": {
"@kie-tools-core/i18n": "workspace:*",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module.exports = {
"jest-junit",
{
suiteName: "Chrome Extension for BPMN and DMN",
outputFile: "./dist-e2e-tests/junit-report.xml",
outputFile: "./dist-tests-e2e/junit-report.xml",
classNameTemplate: "Chrome Extension for BPMN and DMN ::",
titleTemplate: "{title}",
ancestorSeparator: " :: ",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
},
"scripts": {
"build:dev": "rimraf dist && webpack --env dev",
"build:prod": "pnpm lint && pnpm test && rimraf dist && webpack && pnpm test:e2e",
"build:prod": "pnpm lint && pnpm test && rimraf dist && webpack && pnpm test-e2e",
"install": "node install.js",
"lint": "run-script-if --bool \"$(build-env linters.run)\" --then \"kie-tools--eslint ./src\"",
"start": "webpack serve --env dev",
"test": "run-script-if --ignore-errors \"$(build-env tests.ignoreFailures)\" --bool \"$(build-env tests.run)\" --then \"jest --silent --verbose --passWithNoTests\"",
"test:e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-e2e-tests\" \"pnpm start-server-and-test test:e2e:start https-get://localhost:$(build-env chromeExtension.dev.port) test:e2e:run\"",
"test:e2e:run": "jest --runInBand -c ./jest.e2e.config.js",
"test:e2e:start": "pnpm start"
"test-e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-tests-e2e\" \"pnpm start-server-and-test test-e2e:start https-get://localhost:$(build-env chromeExtension.dev.port) test-e2e:run\"",
"test-e2e:run": "jest --runInBand -c ./jest.e2e.config.js",
"test-e2e:start": "pnpm start"
},
"dependencies": {
"@kie-tools-core/chrome-extension": "workspace:*",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module.exports = {
"jest-junit",
{
suiteName: "Chrome Extension end-to-end tests for SWF",
outputFile: "./dist-e2e-tests/junit-report.xml",
outputFile: "./dist-tests-e2e/junit-report.xml",
classNameTemplate: "Chrome Extension for SWF",
titleTemplate: "{title}",
ancestorSeparator: " :: ",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
},
"scripts": {
"build:dev": "rimraf dist && webpack --env dev",
"build:prod": "pnpm lint && pnpm test && rimraf dist && webpack && pnpm test:e2e",
"build:prod": "pnpm lint && pnpm test && rimraf dist && webpack && pnpm test-e2e",
"install": "node install.js",
"lint": "run-script-if --bool \"$(build-env linters.run)\" --then \"kie-tools--eslint ./src\"",
"start": "webpack serve --env dev",
"test": "run-script-if --ignore-errors \"$(build-env tests.ignoreFailures)\" --bool \"$(build-env tests.run)\" --then \"jest --silent --verbose --passWithNoTests\"",
"test:e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-e2e-tests\" \"pnpm start-server-and-test test:e2e:start https-get://localhost:$(build-env swfChromeExtension.dev.port) test:e2e:run\"",
"test:e2e:run": "jest --runInBand -c ./jest.e2e.config.js",
"test:e2e:start": "pnpm start"
"test-e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-tests-e2e\" \"pnpm start-server-and-test test-e2e:start https-get://localhost:$(build-env swfChromeExtension.dev.port) test-e2e:run\"",
"test-e2e:run": "jest --runInBand -c ./jest.e2e.config.js",
"test-e2e:start": "pnpm start"
},
"devDependencies": {
"@babel/core": "^7.16.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/chrome-extension-test-helper/src/utils/Tools.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import Window from "./tools/Window";
import { resolve } from "path";

export default class Tools {
private static readonly SCREENSHOTS_DIR: string = resolve("dist-e2e-tests", "screenshots");
private static readonly SCREENSHOTS_DIR: string = resolve("dist-tests-e2e", "screenshots");

private readonly screenShot: Screenshot;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ export default class Driver {
}

// create directory for chrome browser data
const CHROME_DIR: string = resolve("dist-e2e-tests", "chrome_data");
const CHROME_DIR: string = resolve("dist-tests-e2e", "chrome_data");
if (!existsSync(CHROME_DIR)) {
mkdirSync(CHROME_DIR, { recursive: true });
}
Expand All @@ -60,7 +60,7 @@ export default class Driver {
);

// init chrome driver log
const LOGS_DIR: string = resolve("dist-e2e-tests", "logs");
const LOGS_DIR: string = resolve("dist-tests-e2e", "logs");
if (!existsSync(LOGS_DIR)) {
mkdirSync(LOGS_DIR, { recursive: true });
}
Expand Down
12 changes: 6 additions & 6 deletions packages/dmn-editor/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,17 +18,17 @@
],
"scripts": {
"build:dev": "rimraf dist && pnpm copy:css && tsc -p tsconfig.json",
"build:prod": "rimraf dist && pnpm copy:css && pnpm lint && tsc -p tsconfig.json && pnpm test && pnpm test:e2e",
"build:prod": "rimraf dist && pnpm copy:css && pnpm lint && tsc -p tsconfig.json && pnpm test && pnpm test-e2e",
"build:storybook": "storybook build -o dist-storybook",
"copy:css": "copyfiles -u 1 \"src/**/*.{sass,scss,css}\" dist/",
"lint": "run-script-if --bool \"$(build-env linters.run)\" --then \"kie-tools--eslint ./src\"",
"start": "run-script-os",
"start:linux:darwin": "cross-env STORYBOOK_PORT=$(build-env dmnEditor.storybook.port) pnpm storybook-base --storybookArgs=\"dev --no-open\"",
"start:win32": "pnpm powershell \"cross-env STORYBOOK_PORT=$(build-env dmnEditor.storybook.port) pnpm storybook-base --storybookArgs='dev --no-open'",
"start:linux:darwin": "cross-env STORYBOOK_PORT=$(build-env dmnEditor.storybook.port) pnpm kie-tools--storybook --storybookArgs=\"dev --no-open\"",
"start:win32": "pnpm powershell \"cross-env STORYBOOK_PORT=$(build-env dmnEditor.storybook.port) pnpm kie-tools--storybook --storybookArgs='dev --no-open'",
"test": "run-script-if --ignore-errors \"$(build-env tests.ignoreFailures)\" --bool \"$(build-env tests.run)\" --then \"jest --silent --verbose --passWithNoTests\"",
"test:e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-e2e-tests\" \"pnpm test:e2e:run\"",
"test:e2e:open": "pnpm exec playwright show-report dist-e2e-tests/reports",
"test:e2e:run": "pnpm exec playwright test"
"test-e2e": "run-script-if --ignore-errors \"$(build-env endToEndTests.ignoreFailures)\" --bool \"$(build-env endToEndTests.run)\" --then \"pnpm rimraf ./dist-tests-e2e\" \"pnpm test-e2e:run\"",
"test-e2e:open": "pnpm exec playwright show-report dist-tests-e2e/reports",
"test-e2e:run": "pnpm exec playwright test"
},
"dependencies": {
"@kie-tools-core/i18n": "workspace:*",
Expand Down
Loading

0 comments on commit 80c1b67

Please sign in to comment.