fix(ci): install backend deps for frontend tests that import backend code
This commit is contained in:
@@ -108,12 +108,16 @@ test-frontend:
|
|||||||
stage: test
|
stage: test
|
||||||
image: node:18
|
image: node:18
|
||||||
cache:
|
cache:
|
||||||
key: frontend-${CI_COMMIT_REF_SLUG}
|
- key: frontend-${CI_COMMIT_REF_SLUG}
|
||||||
paths:
|
paths:
|
||||||
- frontend/node_modules/
|
- frontend/node_modules/
|
||||||
policy: pull
|
policy: pull
|
||||||
|
- key: backend-${CI_COMMIT_REF_SLUG}
|
||||||
|
paths:
|
||||||
|
- node_modules/
|
||||||
|
policy: pull
|
||||||
script:
|
script:
|
||||||
- cd frontend && (test -d node_modules || npm ci) && CI=true npx react-scripts test --watchAll=false --ci --testPathIgnorePatterns='atlasMetricsAggregation.property.test'
|
- cd frontend && (test -d node_modules || npm ci) && cd .. && (test -d node_modules || npm ci) && cd frontend && CI=true npx react-scripts test --watchAll=false --ci
|
||||||
timeout: 5 minutes
|
timeout: 5 minutes
|
||||||
needs:
|
needs:
|
||||||
- install-frontend
|
- install-frontend
|
||||||
|
|||||||
Reference in New Issue
Block a user