generated from SAP/repository-template
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor: Combine actions / make e2e test runnable locally
- Loading branch information
Showing
13 changed files
with
68 additions
and
104 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
name: e2e tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
e2e: | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Use Node.js 20.11.0 | ||
uses: actions/[email protected] | ||
with: | ||
node-version: 20.11.0 | ||
|
||
- name: Install dependencies | ||
run: npm ci | ||
|
||
- name: Run e2e tests | ||
run: npm run e2e |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -109,3 +109,4 @@ dist | |
|
||
# Temporary files | ||
/tmp/ | ||
/test/tmp/ |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,5 @@ | ||
import defaultAvaConfig from "./ava.config.js"; | ||
|
||
defaultAvaConfig.files = [ | ||
"test/e2e/**/*.ts", | ||
"!test/e2e/ci-compare.ts", | ||
]; | ||
defaultAvaConfig.files = ["test/e2e/**/*.ts"]; | ||
|
||
export default defaultAvaConfig; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import test from "ava"; | ||
import {readFile} from "node:fs/promises"; | ||
|
||
const E2E_DIR_URL = new URL("../tmp/e2e/", import.meta.url); | ||
|
||
test.serial("Compare com.ui5.troublesome.app result snapshots", async (t) => { | ||
const stderr = await readFile(new URL("stderr.log", E2E_DIR_URL), {encoding: "utf-8"}); | ||
t.snapshot(stderr); | ||
const results = JSON.parse(await readFile(new URL("ui5lint-results.json", E2E_DIR_URL), {encoding: "utf-8"})); | ||
t.snapshot(results); | ||
}); |
Binary file not shown.
10 changes: 7 additions & 3 deletions
10
test/e2e/snapshots/ci-compare.ts.md → test/e2e/snapshots/compare-snapshots.ts.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.