https://cypress.io logo
Hi all. Trying to use the Github Action to do Cypr...
# e2e-testing
b
Hi all. Trying to use the Github Action to do Cypress testing on my Gatsby JS site. Here is what I have so far
Copy code
steps:
    - uses: actions/checkout@v3
    - name: Use Node.js ${{ matrix.node-version }}
      uses: actions/setup-node@v3
      with:
        node-version: ${{ matrix.node-version }}
        cache: 'npm'
    - name: Install dependencies
      run: npm ci
    - name: Cypress run
      uses: cypress-io/github-action@v4
      with:
        start: npm run develop
        record: true
        wait-on: 'http://localhost:8000'
        wait-on-timeout: 120
      env:
        CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
        GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
the
npm develop
job is
"develop": "gatsby develop",
which starts a server on port 8000 The logs state that the Gatsby
develop
job has ran successfully:
Copy code
You can now view your project in the browser.
⠀
  http://localhost:8000/
But Cypress fails to run. This is the error
Copy code
http://localhost:8000 timed out on retry 271 of 9, elapsed 270697ms, limit 270000ms
Error: connect ECONNREFUSED 127.0.0.1:8000