Skip to content

Commit

Permalink
Merge branch 'main' into ORV2-3042, fix conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
zgong-gov committed Jan 10, 2025
2 parents b093400 + aa12d4e commit 97db8e1
Show file tree
Hide file tree
Showing 363 changed files with 26,266 additions and 33,256 deletions.
74 changes: 0 additions & 74 deletions .github/workflows/.tests.yml

This file was deleted.

111 changes: 111 additions & 0 deletions .github/workflows/e2e-regression-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
name: E2E Regression Tests

on:
workflow_call:
inputs:
### Required
target:
description: 'PR number, test, uat or prod.'
default: 'test'
required: true
type: string
show_artifact:
description: 'boolean to show artifacts on run (default is on failure)'
default: 'false'
required: true
type: boolean
workflow_dispatch:
inputs:
### Required
target:
description: 'PR number, test, uat or prod.'
default: 'test'
required: true
type: string
show_artifact:
description: 'boolean to show artifacts on run (default is on failure)'
default: 'false'
required: true
type: boolean


jobs:
vars:
name: Set Variables
outputs:
target: ${{ steps.env.outputs.target }}
environment: ${{ steps.env.outputs.environment }}
runs-on: ubuntu-22.04
steps:
- name: env
id: env
run: |
pr="${{inputs.target}}"
if [[ $pr != 'test' && $pr != 'demo' && $pr != 'uat' && $pr != 'prod' ]]; then
target="$pr"
environment="dev"
else
target=${{inputs.target}}
environment=${{inputs.target}}
fi
echo "target=$target" >> $GITHUB_OUTPUT
echo "environment=$environment" >> $GITHUB_OUTPUT
e2e-tests:
name: ${{matrix.test}}
needs: [vars]
environment: ${{needs.vars.outputs.environment}}
runs-on: ubuntu-22.04
defaults:
run:
working-directory: tests/
strategy:
fail-fast: false
matrix:
browser:
- chrome
#- edge
#- firefox
test:
- 'bceid-crud-power-units.cy.js'
- 'bceid-crud-trailers.cy.js'
- 'bceid-new-term-oversize.cy.js'
- 'bceid-new-term-overweight.cy.js'
- 'bceid-update-term-oversize.cy.js'
- 'idir-amend-term-oversize.cy.js'
- 'idir-void-term-oversize.cy.js'

timeout-minutes: 10
steps:
- uses: actions/checkout@v4

- uses: cypress-io/[email protected]
name: Cypress run
env:
CYPRESS_baseUrl: https://${{ github.event.repository.name }}-${{ needs.vars.outputs.target || 'test' }}-frontend.apps.silver.devops.gov.bc.ca/
CYPRESS_bceid_username: ${{vars.BCEID_USERNAME}}
CYPRESS_bceid_password: ${{secrets.BCEID_PASSWORD}}
CYPRESS_idir_username: ${{vars.IDIR_USERNAME}}
CYPRESS_idir_password: ${{secrets.IDIR_PASSWORD}}
CYPRESS_wait_time: 2000
with:
browser: ${{ matrix.browser }}
config: pageLoadTimeout=10000,video=true
spec: cypress/e2e/${{matrix.test}}
working-directory: tests

- uses: actions/upload-artifact@v4
if: failure() || inputs.show_artifact
with:
name: ${{matrix.test}}-${{matrix.browser}} screenshot
path: tests/cypress/screenshots/
if-no-files-found: ignore # 'warn' or 'error' are also available, defaults to `warn`

- uses: actions/upload-artifact@v4
if: failure() || inputs.show_artifact
with:
name: ${{matrix.test}}-${{matrix.browser}} video
path: tests/cypress/videos/
overwrite: true
if-no-files-found: ignore # 'warn' or 'error' are also available, defaults to `warn`

2 changes: 1 addition & 1 deletion .github/workflows/notifications.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Notifications
on:
workflow_run:
workflows: [PR,Merge]
workflows: ['PR Opened',Merge]
types:
- completed
jobs:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr-open.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: PR
name: PR Opened

on:
pull_request:
Expand Down
11 changes: 8 additions & 3 deletions charts/onroutebc/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ scheduler:
license: "{{.Values.global.license}}"
secretPaths:
- "keycloak-{{tpl $.Values.vault.zone $}}"
- "mssql-{{tpl $.Values.vault.zone $}}"
- "mssql-{{tpl $.Values.vault.zone $}}"
- "scheduler-{{tpl $.Values.vault.zone $}}"
- "s3-{{tpl $.Values.vault.zone $}}"
- "cfs-{{tpl $.Values.vault.zone $}}"
Expand All @@ -563,7 +563,9 @@ policy:
secret:
enabled: false
configmap:
enabled: false
enabled: true
data:
FRONTEND_URL: "https://{{.Release.Name}}-frontend.apps.silver.devops.gov.bc.ca"
containers:
- name: policy
command:
Expand All @@ -574,7 +576,10 @@ policy:
repository: '{{ .Values.global.repository }}' # example, it includes registry and repository
image: policy
tag: "{{tpl .Values.global.tag .}}"
env:
env:
fromLocalConfigmap:
- name: FRONTEND_URL
key: FRONTEND_URL
fromValues:
- name: POLICY_PR_NUM
value: '{{.Values.global.pr_num}}'
Expand Down
Loading

0 comments on commit 97db8e1

Please sign in to comment.