Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
823eb2d
feat(ci): Upload CRA Cypress screenshots on failure
yogeshchoudhary147 Oct 14, 2025
34de3f7
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 14, 2025
0529bb2
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 14, 2025
7371183
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 14, 2025
0cc2fc3
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 14, 2025
8d0863b
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 14, 2025
fd44c97
Merge branch 'main' into upload-cypress-cra-screenshots
yogeshchoudhary147 Oct 16, 2025
23a03e6
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 16, 2025
4a4e09b
fix(ci): switch Cypress browser to Chrome to fix redirect issues in CI
yogeshchoudhary147 Oct 16, 2025
e06706c
fix(ci): stablize headless Chrome in Cypress by moving sandbox flags …
yogeshchoudhary147 Oct 16, 2025
e651eea
fix(ci): stablize headless Chrome in Cypress by moving sandbox flags …
yogeshchoudhary147 Oct 16, 2025
9b2c76d
fix(ci): wait for app to start before running Cypress tests
yogeshchoudhary147 Oct 16, 2025
72fffa6
fix(ci): stablize Cypress Chrome runs on GitHub Actions by moving Chr…
yogeshchoudhary147 Oct 16, 2025
1c3756d
fix(ci): add health check to ensure app is running before Cypress tests
yogeshchoudhary147 Oct 16, 2025
b21e568
chore(ci): debug CRA app startup before Cypress run
yogeshchoudhary147 Oct 16, 2025
88d190d
fix(ci): ensure CRA app is fully up before running Cypress tests
yogeshchoudhary147 Oct 16, 2025
d3e7259
fix(ci): add Chrome flags to stablize Cypress in GitHub Actions
yogeshchoudhary147 Oct 16, 2025
ceacdf3
fix(ci): ensure CRA app is ready before running cypress test
yogeshchoudhary147 Oct 16, 2025
bce373b
fix(ci): ensure CRA app is ready before running Cypress tests
yogeshchoudhary147 Oct 16, 2025
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
32 changes: 31 additions & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,38 @@ jobs:
- name: Install examples
run: npm run install:examples

- name: Start servers
run: |
npm run start:api > api.log 2>&1 &
npm run start:cra > cra.log 2>&1 &

- name: Wait for app to be reachable
run: |
echo "Waiting for CRA app to respond on port 3000..."
for i in {1..20}; do
if curl -s http://127.0.0.1:3000 > /dev/null; then
echo "App is up!"
break
fi
echo "Still waiting... ($i)"
sleep 3
done

- name: Run integration test (CRA)
run: npm run test:cra
run: |
npx wait-on http://127.0.0.1:3000
npx cypress run --spec 'cypress/e2e/smoke.cy.ts' --browser chrome --headless
env:
CI: true

- name: Upload cypress screeshots (CRA)
if: failure()
uses: actions/upload-artifact@v4
with:
name: cypress-screenshots-cra-${{ github.run_id }}
path: cypress/screenshots/**
retention-days: 30
compression-level: 6

- name: Run integration test (NextJS)
run: npm run test:nextjs
Expand Down
14 changes: 13 additions & 1 deletion cypress.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,19 @@ module.exports = defineConfig({
mochaFile: 'test-results/cypress/junit-[hash].xml',
},
e2e: {
setupNodeEvents(on, config) {},
setupNodeEvents(on, config) {
on('before:browser:launch', (browser = {}, launchOptions) => {
if (browser.name === 'chrome' || browser.name === 'chromium') {
launchOptions.args.push('--no-sandbox')
launchOptions.args.push('--disable-gpu')
launchOptions.args.push('--disable-dev-shm-usage')
launchOptions.args.push('--disable-setuid-sandbox')
launchOptions.args.push('--disable-web-security')
}
return launchOptions
})
return config
},
baseUrl: 'http://localhost:3000',
supportFile: false,
},
Expand Down
Loading