Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PC 33838 pro allure report #15954

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 41 additions & 16 deletions .github/workflows/dev_on_pull_request_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -243,12 +243,12 @@ jobs:
GCP_EHP_WORKLOAD_IDENTITY_PROVIDER: ${{ secrets.GCP_EHP_WORKLOAD_IDENTITY_PROVIDER }}
GCP_EHP_SERVICE_ACCOUNT: ${{ secrets.GCP_EHP_SERVICE_ACCOUNT }}

merge-allure-reports:
name: "Merge Allure Reports and Push to Allure Repository"
download-allure-pro-unit:
name: "Download Allure results artifacts for pro unit"
needs: [pcapi-init-job, test-pro]
runs-on: ubuntu-22.04
if: |
always() &&
always() &&
!cancelled() && needs.test-pro.result != 'skipped'
steps:
- name: "Install Allure CLI via Yarn"
Expand All @@ -260,16 +260,36 @@ jobs:
name: allure-results-pro-unit
path: allure-results/pro-unit

# - name: "Download Allure results artifacts for pro E2E"
# uses: actions/download-artifact@v4
# with:
# name: allure-results-pro-e2e
# path: allure-results/pro-e2e
download-allure-pro-e2e:
name: "Download Allure results artifacts for pro E2E"
needs: [pcapi-init-job, test-pro-e2e]
runs-on: ubuntu-22.04
if: |
always() &&
!cancelled() && needs.test-pro-e2e.result != 'skipped'
steps:
- name: "Install Allure CLI via Yarn"
run: yarn global add allure-commandline

- name: "Download Allure results artifacts for pro E2E"
uses: actions/download-artifact@v4
with:
name: allure-results-pro-e2e
path: allure-results/pro-e2e

merge-allure-reports:
name: "Merge Allure Reports and Push to Allure Repository"
needs: [pcapi-init-job, test-pro, test-pro-e2e]
runs-on: ubuntu-22.04
if: |
always() &&
!cancelled() && needs.test-pro.result != 'skipped'
&& needs.test-pro-e2e.result != 'skipped'
steps:
- name: "Merge Allure Results"
run: |
mkdir -p allure-results
cp -r allure-results/pro-unit/* allure-results/
cp -r allure-results/pro-unit/* allure-results/pro-e2e/* allure-results/

- name: "Clone Allure Report Repository to Retrieve History"
env:
Expand All @@ -281,14 +301,19 @@ jobs:
cp -r allure-report-temp/history/* allure-results/history/
fi

- name: "Generate Allure Report with History"
run: allure generate allure-results --single-file --clean -o allure-report
- name: "Generate Allure Report with Updated History"
run: allure generate allure-results --clean -o allure-report

- name: "Upload Allure Report as artifact"
uses: actions/upload-artifact@v4
with:
name: allure-report
path: allure-report/index.html
- name: "Push Updated Allure Report with History to Repository"
run: |
cd allure-report-temp
rm -rf *
cp -r ../allure-report/* .
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "Update Allure Report with history"
git push origin main

dependabot-auto-merge:
name: "Dependabot"
Expand Down
40 changes: 30 additions & 10 deletions .github/workflows/dev_on_push_workflow_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,12 @@ jobs:
GCP_EHP_WORKLOAD_IDENTITY_PROVIDER: ${{ secrets.GCP_EHP_WORKLOAD_IDENTITY_PROVIDER }}
GCP_EHP_SERVICE_ACCOUNT: ${{ secrets.GCP_EHP_SERVICE_ACCOUNT }}

merge-allure-reports:
name: "Merge Allure Reports and Push to Allure Repository"
needs: [test-pro]
download-allure-pro-unit:
name: "Download Allure results artifacts for pro unit"
needs: [pcapi-init-job, test-pro]
runs-on: ubuntu-22.04
if: |
always() &&
always() &&
!cancelled() && needs.test-pro.result != 'skipped'
steps:
- name: "Install Allure CLI via Yarn"
Expand All @@ -258,16 +258,36 @@ jobs:
name: allure-results-pro-unit
path: allure-results/pro-unit

# - name: "Download Allure results artifacts for pro E2E"
# uses: actions/download-artifact@v4
# with:
# name: allure-results-pro-e2e
# path: allure-results/pro-e2e
download-allure-pro-e2e:
name: "Download Allure results artifacts for pro E2E"
needs: [pcapi-init-job, test-pro-e2e]
runs-on: ubuntu-22.04
if: |
always() &&
!cancelled() && needs.test-pro-e2e.result != 'skipped'
steps:
- name: "Install Allure CLI via Yarn"
run: yarn global add allure-commandline

- name: "Download Allure results artifacts for pro E2E"
uses: actions/download-artifact@v4
with:
name: allure-results-pro-e2e
path: allure-results/pro-e2e

merge-allure-reports:
name: "Merge Allure Reports and Push to Allure Repository"
needs: [pcapi-init-job, test-pro, test-pro-e2e]
runs-on: ubuntu-22.04
if: |
always() &&
!cancelled() && needs.test-pro.result != 'skipped'
&& needs.test-pro-e2e.result != 'skipped'
steps:
- name: "Merge Allure Results"
run: |
mkdir -p allure-results
cp -r allure-results/pro-unit/* allure-results/
cp -r allure-results/pro-unit/* allure-results/pro-e2e/* allure-results/

- name: "Clone Allure Report Repository to Retrieve History"
env:
Expand Down
15 changes: 8 additions & 7 deletions .github/workflows/dev_on_workflow_tests_pro_e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -152,14 +152,15 @@ jobs:
CYPRESS_PROJECT_ID: ${{ steps.secrets.outputs.CYPRESS_CLOUD_PROJECT_ID }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

# - name: "Remove Cypress videos from Allure results"
# run: rm -rf ../allure-results/*.mp4
- name: "Remove Cypress videos from Allure results"
run: rm -rf ../allure-results/*.mp4

# - name: "Upload Allure results for pro E2E tests"
# uses: actions/upload-artifact@v4
# with:
# name: allure-results-pro-e2e
# path: allure-results
- name: "Upload Allure results for pro E2E tests"
uses: actions/upload-artifact@v4
if: always()
with:
name: allure-results-pro-e2e
path: allure-results

- name: "Move cypress videos"
if: always() && failure() && github.ref != 'refs/heads/master' # useless on master bc Cypress Cloud
Expand Down
8 changes: 4 additions & 4 deletions pro/cypress/cypress.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import fs from 'fs'

// import { allureCypress } from 'allure-cypress/reporter'
import { allureCypress } from 'allure-cypress/reporter'
import { defineConfig } from 'cypress'
import cypressFailFast = require('cypress-fail-fast/plugin')

Expand All @@ -24,9 +24,9 @@ export default defineConfig({
}
}
)
// allureCypress(on, config, {
// resultsDir: '../../allure-results',
// })
allureCypress(on, config, {
resultsDir: '../../allure-results',
})
// Make sure to return the config object as it might have been modified by the plugin.
return config
},
Expand Down
2 changes: 1 addition & 1 deletion pro/cypress/support/e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import './commands'
import './helpers'
import { configure } from '@testing-library/react'
import 'cypress-fail-fast'
// import 'allure-cypress'
import 'allure-cypress'

// Set to `defaultCommandTimeout` to match the cypress default timeout
configure({ asyncUtilTimeout: 4000 })
1 change: 1 addition & 0 deletions pro/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@
"@vitest/runner": "^2.1.7",
"allure-js-commons": "^3.0.8",
"allure-vitest": "^3.0.9",
"allure-cypress": "^3.0.9",
"cypress": "^13.17.0",
"cypress-fail-fast": "^7.1.1",
"eslint": "9.18.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import { AccessibilityLabel } from 'ui-kit/AccessibilityLabel/AccessibilityLabel

import styles from './AccessibilitySummarySection.module.scss'

// This interface is verified by both collective/individual offers and venues
interface AccessibleItem {
audioDisabilityCompliant?: boolean | null
mentalDisabilityCompliant?: boolean | null
Expand Down
19 changes: 7 additions & 12 deletions pro/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1951,13 +1951,6 @@
util "^0.12.5"
ws "^8.2.3"

"@storybook/[email protected]":
version "8.5.0"
resolved "https://registry.yarnpkg.com/@storybook/csf-plugin/-/csf-plugin-8.5.0.tgz#f071c2fb9de5941654b00c95354ee7337d61fc7e"
integrity sha512-cs6ogviNyLG1h9J8Sb47U3DqIrQmn2EHm4ta3fpCeV3ABbrMgbzYyxtmybz4g/AwlDgjAZAt6PPcXkfCJ6p2CQ==
dependencies:
unplugin "^1.3.1"

"@storybook/[email protected]":
version "8.5.1"
resolved "https://registry.yarnpkg.com/@storybook/csf-plugin/-/csf-plugin-8.5.1.tgz#626efa6db0009145e6ffa6019b34d8d48b17041c"
Expand Down Expand Up @@ -2005,11 +1998,6 @@
resolved "https://registry.yarnpkg.com/@storybook/preview-api/-/preview-api-8.5.1.tgz#d21b6a72adc3692ec3128aef4b3ad8cee749ac28"
integrity sha512-fLR7nvAbjHVLazDA6CLy9O/bpBzKDKqxyBp6SybTBPYa76IzsX8ITSMMt1YcP6rOGhVgcKNA9iBNxRddjLIV0Q==

"@storybook/[email protected]":
version "8.5.0"
resolved "https://registry.yarnpkg.com/@storybook/react-dom-shim/-/react-dom-shim-8.5.0.tgz#ada85ed027113b0e05debfd5c5e6ffa44843b069"
integrity sha512-7P8xg4FiuFpM6kQOzZynno+0zyLVs8NgsmRK58t3JRZXbda1tzlxTXzvqx4hUevvbPJGjmrB0F3xTFH+8Otnvw==

"@storybook/[email protected]":
version "8.5.1"
resolved "https://registry.yarnpkg.com/@storybook/react-dom-shim/-/react-dom-shim-8.5.1.tgz#57dbf09c616ed655289b5050c171a1b02f7ae028"
Expand Down Expand Up @@ -2677,6 +2665,13 @@ algoliasearch@>=4:
"@algolia/requester-node-http" "4.19.1"
"@algolia/transporter" "4.19.1"

allure-cypress@^3.0.9:
version "3.0.9"
resolved "https://registry.yarnpkg.com/allure-cypress/-/allure-cypress-3.0.9.tgz#9437463b07baeaa135af96d5fac95481d6528814"
integrity sha512-nK+WGRSjOXXV4BvmKvJNgqPLjWQ0OJVGcYrK/Gxg/C1R9zru91YnNAz/nUbRKrnHEzWMNhxBinB6nLD1Y/4NAQ==
dependencies:
allure-js-commons "3.0.9"

[email protected], allure-js-commons@^3.0.8:
version "3.0.9"
resolved "https://registry.yarnpkg.com/allure-js-commons/-/allure-js-commons-3.0.9.tgz#8664a523284b590901f1ead53f46e2abb2d312e8"
Expand Down
Loading