Skip to content

Commit

Permalink
Attempt to fix Cypress caching #2 (#9266)
Browse files Browse the repository at this point in the history
* Attempt to fix cypress caching

* Revert "build: Fix Component Governance in Composer DevOps pipeline (#9257)"

This reverts commit b6032af.

* Fix e2e-ci calling npx instead of yarn
  • Loading branch information
OEvgeny authored Jun 28, 2022
1 parent 223d9a3 commit 68d5d4f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 25 deletions.
3 changes: 2 additions & 1 deletion Composer/packages/integration-tests/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
"open": "cypress open",
"clean": "node scripts/clean-e2e.js",
"clean-all": "node scripts/clean-e2e.js --all",
"lint": "eslint --quiet cypress"
"lint": "eslint --quiet cypress",
"cypress": "cypress run"
},
"keywords": [],
"author": "",
Expand Down
2 changes: 1 addition & 1 deletion Composer/packages/integration-tests/scripts/e2e-ci.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ yarn start >> e2e.log 2>&1 &
SERVER_PID=$!

cd packages/integration-tests
npx cypress run "$@"
yarn run cypress -- "$@"
EXIT_CODE=$?

# kill server process
Expand Down
23 changes: 0 additions & 23 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,33 +88,10 @@ jobs:
pool:
vmImage: ubuntu-latest
steps:
- powershell: |
# Gin up imitation v1 yarn.lock files to aid Component Governance Detection analysis. The method:
# Find v3 yarn-berry.lock files. From each, generate a yarn.lock file, deleting all occurrences of 'npm:'.
# This allows CG to work with yarn v3.
$find = 'npm:';
$replace = '';
Get-ChildItem -Recurse -Path '**/yarn-berry.lock' | % {
$source = $_.FullName;
$dest = $_.DirectoryName + "/yarn.lock"
Write-Host $source;
Write-Host $dest;
Copy-Item -Path $source -Destination $dest -Force
$content = Get-Content -Raw $dest;
$content -Replace "$find", "$replace" | Set-Content $dest;
'--------------------'; get-content $dest; '====================';
}
displayName: Generate "yarn.lock" files for CG Detection
continueOnError: true
- task: ComponentGovernanceComponentDetection@0
displayName: Component Detection
inputs:
scanType: "Register"
verbosity: "Verbose"
alertWarningLevel: "High"
failOnAlert: true

0 comments on commit 68d5d4f

Please sign in to comment.