-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Fix and upgrade cypress integration tests * Remove unneeded code and packages * Remove unused ports from docker-compose.yml * Rename task and set where to run * Fix naming of job * Update workflow action dependencies * Add individual names to steps * Add webpacker as dev dependency * Replace entrypoint and remove unneeded packags in package.json * explicit network managment * fixing test env * Increase Time settings * Fix local setup. --------- Co-authored-by: Splines <[email protected]>
- Loading branch information
Showing
25 changed files
with
104 additions
and
3,595 deletions.
There are no files selected for viewing
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,26 +1,41 @@ | ||
name: test-integration | ||
on: [push] | ||
name: Integration tests | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- mampf-next | ||
- production | ||
- experimental | ||
pull_request: | ||
jobs: | ||
build: | ||
e2e-test-job: | ||
name: Run E2E tests & upload results to Cypress | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v2 | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- run: docker-compose pull | ||
|
||
- name: Pull docker images | ||
run: docker compose pull --ignore-buildable | ||
working-directory: docker/run_cypress_tests | ||
- uses: satackey/[email protected] | ||
# Ignore the failure of a step and avoid terminating the job. | ||
|
||
- name: Use Docker layer caching # https://github.com/jpribyl/action-docker-layer-caching | ||
uses: jpribyl/[email protected] | ||
continue-on-error: true | ||
- run: docker-compose build | ||
|
||
- name: Build docker containers | ||
run: docker compose build | ||
working-directory: docker/run_cypress_tests | ||
- name: Test | ||
|
||
- name: Run integration tests | ||
working-directory: docker/run_cypress_tests | ||
env: | ||
# pass the Dashboard record key as an environment variable | ||
CYPRESS_baseUrl: http://mampf:3000 | ||
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }} | ||
# pass GitHub token to allow accurately detecting a build vs a re-run build | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: docker-compose run -e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} cypress_runner cypress run --record --key ${{ secrets.CYPRESS_RECORD_KEY }} | ||
run: docker compose run -e GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }} --entrypoint="" cypress_runner sh -c "while ! curl http://mampf:3000 ; do echo waiting for MaMpf to come online at http://mampf:3000; sleep 3; done; cypress run --record --key ${{ secrets.CYPRESS_RECORD_KEY }}" |
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 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,5 +1,5 @@ | ||
FROM cypress/included:7.6.0 | ||
FROM cypress/included:12.9.0 | ||
|
||
COPY ./spec/cypress/support /cypress/support | ||
# install the needed support stuff | ||
RUN cd /cypress/support && yarn install | ||
RUN apt-get update && apt-get install curl -y |
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 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 |
---|---|---|
|
@@ -20,8 +20,5 @@ | |
}, | ||
"scripts": { | ||
"lint": "eslint ." | ||
}, | ||
"devDependencies": { | ||
"cypress": "9.5.1" | ||
} | ||
} | ||
} |
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,13 @@ | ||
const { defineConfig } = require('cypress') | ||
|
||
module.exports = defineConfig({ | ||
e2e:{ | ||
"baseUrl": "http://localhost:3000", | ||
"defaultCommandTimeout": 10000, | ||
"projectId": "v45wg9", | ||
"retries": { | ||
"runMode": 2, | ||
"openMode": 0 | ||
} | ||
} | ||
}) |
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
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
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
File renamed without changes.
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
File renamed without changes.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
import './commands' | ||
import './on-rails' |
Oops, something went wrong.