Skip to content

Commit

Permalink
ci(panel): cypress improvements (grafana#1272)
Browse files Browse the repository at this point in the history
  • Loading branch information
eh-am authored Jul 15, 2022
1 parent c62eda2 commit 054dd6f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 20 deletions.
22 changes: 3 additions & 19 deletions .github/workflows/cypress-panel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,7 @@ jobs:
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn
- run: yarn
# when building hide the logo
env:
PYROSCOPE_HIDE_LOGO: true

- run: yarn --frozen-lockfile
- run: yarn build:panel
env:
PYROSCOPE_PANEL_VERSION: test
Expand All @@ -39,24 +35,12 @@ jobs:
- name: Cypress run
uses: cypress-io/github-action@v2
with:
config-file: packages/pyroscope-panel-plugin/cypress.json
command: yarn cy:panel:ci
wait-on: http://localhost:3000
start: make server
env:
CYPRESS_VIDEO: true
CYPRESS_COMPARE_SNAPSHOTS: true
- uses: actions/upload-artifact@v2
if: always()
with:
name: cypress-screenshots
path: cypress/screenshots
- uses: actions/upload-artifact@v2
if: always()
with:
name: cypress-videos
path: cypress/videos
- uses: actions/upload-artifact@v2
if: always()
if: failure()
with:
name: cypress-snapshots
path: cypress/snapshots
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@
"cy:webapp-base-url:ci": "cypress run --config-file cypress/base-url/cypress.json",
"cy:webapp-base-url:ss-check": "CYPRESS_updateSnapshots=false ./scripts/cypress-screenshots.sh --config-file cypress/base-url/cypress.json",
"cy:panel:open": "cypress open --config-file grafana-plugin/panel/cypress.json",
"cy:panel:ci": "cypress run --config-file grafana-plugin/panel/cypress.json",
"cy:panel:ci": "cypress run --config-file packages/pyroscope-panel-plugin/cypress.json",
"cy:panel:ss": "./scripts/cypress-screenshots.sh --config-file packages/pyroscope-panel-plugin/cypress.json",
"cy:panel:ss-check": "CYPRESS_updateSnapshots=false ./scripts/cypress-screenshots.sh --config-file packages/pyroscope-panel-plugin/cypress.json",
"cy:datasource:open": "cypress open --config-file packages/pyroscope-datasource-plugin/cypress.json",
Expand Down
1 change: 1 addition & 0 deletions packages/pyroscope-panel-plugin/cypress.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"baseUrl": "http://localhost:3000",
"integrationFolder": "cypress/integration/panel",
"reporter": "cypress-image-snapshot/reporter",
"retries": {
"runMode": 5
}
Expand Down

0 comments on commit 054dd6f

Please sign in to comment.