Skip to content

Commit

Permalink
Merge pull request #30 from catenax-ng/main
Browse files Browse the repository at this point in the history
Preparations for release 1.1.2
  • Loading branch information
ds-jkreutzfeld authored Mar 1, 2023
2 parents adb2bc0 + 6d5f49f commit 0962368
Show file tree
Hide file tree
Showing 130 changed files with 5,158 additions and 3,721 deletions.
2 changes: 1 addition & 1 deletion .github/scripts/eclipse_dash.sh
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
java -jar org.eclipse.dash.licenses-0.0.1-20221105.055038-599.jar yarn.lock -project automotive.tractusx -summary DASH_SUMMARY
grep "restricted" DASH_SUMMARY | if test $(wc -l) -gt 0; then exit 1; fi
grep -E '(restricted, #)|(restricted$)' DASH_SUMMARY | if test $(wc -l) -gt 0; then exit 1; fi
Original file line number Diff line number Diff line change
@@ -1,19 +1,26 @@
name: E2E Tests
# Require to set secrets:
# - ORG_IRS_JIRA_USERNAME
# - ORG_IRS_JIRA_PASSWORD
name: E2E Tests - Xray

on:
# triggered manually by Test Manager
workflow_dispatch:
inputs:
jira_filter_id:
description: 'Jira filter ID to fetch test scenarios'
required: false
# by default, we use this filter: https://jira.catena-x.net/issues/?filter=11645
default: 11645
# or automatically by merge to main
push:
branches: [ main ]
# or in PR
pull_request:

jobs:
install:
runs-on: ubuntu-latest
container:
# if you need to change image please make sure use the same version in all places
# (here and in cypress/Dockerfile)
image: cypress/browsers:node16.16.0-chrome107-ff107-edge
options: --user 1001

# Install YARN dependencies, cache them correctly
steps:
- name: Checkout
Expand All @@ -29,10 +36,28 @@ jobs:
with:
cmd: install # will run `yarn install` command

# Fetch feature files
- name: Fetch .feature files from Jira Xray
env:
JIRA_USERNAME: ${{ secrets.ORG_IRS_JIRA_USERNAME }}
JIRA_PASSWORD: ${{ secrets.ORG_IRS_JIRA_PASSWORD }}
JIRA_FILTER_ID: ${{ github.event.inputs.jira_filter_id }}
run: |
./scripts/xray-download-feature-files.sh
- name: Save cypress/e2e folder
uses: actions/upload-artifact@v3
with:
name: cypress - e2e
if-no-files-found: error
path: cypress/e2e

cypress-run-chrome:
timeout-minutes: 15
runs-on: ubuntu-latest
container:
# if you need to change image please make sure use the same version in all places
# (here and in cypress/Dockerfile)
image: cypress/browsers:node16.16.0-chrome107-ff107-edge
options: --user 1001
needs: install
Expand All @@ -41,6 +66,12 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Download the cypress/e2e folder
uses: actions/download-artifact@v3
with:
name: cypress - e2e
path: cypress/e2e

- name: Use Node.js 18.x
uses: actions/setup-node@v3
with:
Expand All @@ -54,6 +85,15 @@ jobs:
wait-on-timeout: 120
browser: chrome

- name: Submit results to Xray
# we don't want to submit results to xray when it was run by PR
if: github.event_name != 'pull_request' && (success() || failure())
env:
JIRA_USERNAME: ${{ secrets.ORG_IRS_JIRA_USERNAME }}
JIRA_PASSWORD: ${{ secrets.ORG_IRS_JIRA_PASSWORD }}
run: |
./scripts/xray-push-test-results.sh
- name: Archive cypress artifacts
if: success() || failure()
uses: actions/upload-artifact@v3
Expand All @@ -67,6 +107,8 @@ jobs:
timeout-minutes: 15
runs-on: ubuntu-latest
container:
# if you need to change image please make sure use the same version in all places
# (here and in cypress/Dockerfile)
image: cypress/browsers:node16.16.0-chrome107-ff107-edge
options: --user 1001
needs: install
Expand All @@ -75,6 +117,12 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Download the cypress/e2e folder
uses: actions/download-artifact@v3
with:
name: cypress - e2e
path: cypress/e2e

- name: Use Node.js 18.x
uses: actions/setup-node@v3
with:
Expand All @@ -88,6 +136,15 @@ jobs:
wait-on-timeout: 120
browser: firefox

- name: Submit results to Xray
# we don't want to submit results to xray when it was run by PR
if: github.event_name != 'pull_request' && (success() || failure())
env:
JIRA_USERNAME: ${{ secrets.ORG_IRS_JIRA_USERNAME }}
JIRA_PASSWORD: ${{ secrets.ORG_IRS_JIRA_PASSWORD }}
run: |
./scripts/xray-push-test-results.sh
- name: Archive cypress artifacts
if: success() || failure()
uses: actions/upload-artifact@v3
Expand All @@ -106,6 +163,12 @@ jobs:
- name: Checkout
uses: actions/checkout@v3

- name: Download the cypress/e2e folder
uses: actions/download-artifact@v3
with:
name: cypress - e2e
path: cypress/e2e

# commented because if we use it here, we face with that problem:
# "http://localhost:4200 timed out on retry 151 of 5, elapsed 150449ms, limit 150000ms
# Error: connect ECONNREFUSED 127.0.0.1:4200"
Expand All @@ -132,6 +195,15 @@ jobs:
wait-on-timeout: 120
browser: webkit

- name: Submit results to Xray
# we don't want to submit results to xray when it was run by PR
if: github.event_name != 'pull_request' && (success() || failure())
env:
JIRA_USERNAME: ${{ secrets.ORG_IRS_JIRA_USERNAME }}
JIRA_PASSWORD: ${{ secrets.ORG_IRS_JIRA_PASSWORD }}
run: |
./scripts/xray-push-test-results.sh
- name: Archive cypress artifacts
if: success() || failure()
uses: actions/upload-artifact@v3
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ jobs:
build:

runs-on: ubuntu-latest
continue-on-error: true

steps:
- uses: actions/checkout@v3
Expand All @@ -24,9 +25,10 @@ jobs:
cmd: install # will run `yarn install` command
- name: Run npm test:ci
run: CHROMIUM_BIN=$(which chrome) npm run test:ci # will run `test:ci` command
continue-on-error: true
- name: Run SonarCloud with organzation and project key from environment
if: always() && ${{ vars.SONAR_ORGANIZATION != '' && vars.SONAR_PROJECT_KEY != '' }}
uses: SonarSource/sonarcloud-github-action@master
if: ${{ vars.SONAR_ORGANIZATION != '' && vars.SONAR_PROJECT_KEY != '' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
Expand Down
8 changes: 4 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,12 @@ testem.log
/typings
/audit-reports
src/tests/test-report.xml
cypress/videos
cypress/screenshots

# e2e
/e2e/*.js
/e2e/*.map
cypress/videos
cypress/screenshots
cypress/reports/*
cucumber-messages.ndjson

# System Files
.DS_Store
Expand Down
2 changes: 0 additions & 2 deletions AUTHORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,3 @@ The following people have contributed to this repository:
- Nobert Geczi,msg Systems Romania SRL,https://github.com/norbertgeczi
- Markus Kreuz,FEV Consulting GmbH,https://github.com/CXkreuz
- Thomas Braun,ZF Friedrichshafen AG,https://github.com/tbraun-zf


Loading

0 comments on commit 0962368

Please sign in to comment.