Skip to content

Commit

Permalink
Merge pull request #2491 from NationalSecurityAgency/t#2462/oauth_ci_…
Browse files Browse the repository at this point in the history
…fialures

T#2462/oauth ci fialures
  • Loading branch information
sudo-may committed Dec 22, 2023
2 parents a0d44b4 + 8e65296 commit 5e84ed1
Show file tree
Hide file tree
Showing 17 changed files with 385 additions and 394 deletions.
55 changes: 27 additions & 28 deletions .github/workflows/build-and-test-oauth.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,21 +25,24 @@ on:
schedule:
- cron: '0 6 * * *'
workflow_dispatch:

pull_request:
paths-ignore:
- 'README.md'

jobs:
build-skills-service-for-ui-tests:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

- uses: actions/setup-node@v2-beta
- uses: actions/setup-node@v3
with:
node-version: '14'

- uses: actions/setup-java@v1
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '19' # The JDK version to make available on the path.

- name: Print Versions
Expand All @@ -48,7 +51,7 @@ jobs:
java -version
- name: Cache local Maven repository
uses: actions/cache@v2
uses: actions/cache@v3
with:
path: ~/.m2/repository
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
Expand All @@ -61,7 +64,7 @@ jobs:
run: mvn --batch-mode install -DskipTests

- name: upload service jar
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: service jar
path: ./service/target/*.jar
Expand All @@ -77,7 +80,7 @@ jobs:
fail-fast: false
matrix:
# run 6 copies of the current job in parallel
containers: [1, 2, 3, 4, 5, 6]
container: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20]

services:
postgres:
Expand All @@ -101,28 +104,29 @@ jobs:
- name: Install Emoji Support
run: sudo apt-get install fonts-noto-color-emoji

- uses: actions/checkout@v2
- uses: actions/checkout@v3

- name: Checkout skills-client
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
repository: NationalSecurityAgency/skills-client
path: skills-client

- uses: actions/setup-node@v2-beta
- uses: actions/setup-node@v3
with:
node-version: '14'

- uses: actions/setup-java@v1
- uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: '19' # The JDK version to make available on the path.

- name: Print Versions
run: |
mvn --version
java -version
- uses: actions/download-artifact@v2
- uses: actions/download-artifact@v3
with:
name: service jar
path: ./service/target/
Expand Down Expand Up @@ -165,26 +169,21 @@ jobs:
cd ..
- name: Run Cypress tests
uses: cypress-io/github-action@v4
with:
working-directory: e2e-tests
record: true
parallel: true
group: 'skills-service with OAuth'
tag: "${{ github.workflow }}"
env: oauthMode=true
browser: chrome
run: |
cd e2e-tests
../.github/scripts/runSubsetOfCypressTests.sh -t 20 -c ${{ matrix.container }}
cd ..
env:
# pass the Dashboard record key as an environment variable
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 }}
ELECTRON_EXTRA_LAUNCH_ARGS: '--disable-gpu'
cypress_oauthMode: true

- name: upload result artifacts
if: ${{ always() }}
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: CI result artifacts
name: UI test artifacts (${{ matrix.container }})
path: |
./e2e-tests/logs
./e2e-tests/cypress/visualRegression/diff
./e2e-tests/cypress/videos
./e2e-tests/cypress/screenshots
./e2e-tests/cypress/visualRegression/diff
Loading

0 comments on commit 5e84ed1

Please sign in to comment.