TechIsHiring / techishiring-website

A space where great Engineers and great jobs can find each other! We're on Twitter and LinkedIn and have a newsletter on Substack!
https://www.techishiring.com
MIT License
52 stars 34 forks source link

test: update cypress, add component testing in CI, add Cypress Cloud #153

Closed marktnoonan closed 1 year ago

marktnoonan commented 1 year ago

Description

Related Issue

Resolves: #152

Motivation and Context

I realized when we set up component testing, we did not set it to run in GitHub Actions for this project. Also in talking with Chad we decided to set up a Cypress Cloud project to help with test times by running things in parallel. This also gives us a place to review results and assets like videos/screenshots from tests.

The Cloud integration will fail until we set a CYPRESS_RECORD_KEY environment variable in this repository. This run was recorded against my fork of this project.

Additionally I've made a couple of other changes around the testing setup, lets go through them file by file:

code-quality.yml

cypress.config.ts

cypress/e2e/contactuspage.cy.ts and cypress/e2e/contactuspage.cy.ts

Remove http://localhost:3000 from tests, as that is now configured as the baseUrl for this project.

package.json

Update Cypress to the latest version.

How Has This Been Tested?

Here is an example run showing the e2e and component tests have both run, and been parallelized and recorded to Cypress Cloud.

Screenshots (if appropriate):

Run information in Cypress cloud.

Screenshot 2023-07-16 at 4 53 48 PM
vercel[bot] commented 1 year ago

Someone is attempting to deploy a commit to a Personal Account owned by @TechIsHiring on Vercel.

@TechIsHiring first needs to authorize it.

vercel[bot] commented 1 year ago

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
techishiring-website ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 21, 2023 0:09am