Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(#170): Add cypress tests #412

Closed
wants to merge 2 commits into from

Conversation

dougy-fresh
Copy link
Contributor

@dougy-fresh dougy-fresh commented Aug 12, 2023

I only tested index.html and the core documentation, but it'll at least check that the website comes up.

Fixes #170

@@ -0,0 +1,17 @@
const { setupNodeEvents } = require('@tybalt/cypress');
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

packages/website/pages/writing-unit-tests-guide.md Outdated Show resolved Hide resolved
MAINTAINING.md Show resolved Hide resolved
packages/cypress/e2e/website/index.cy.js Outdated Show resolved Hide resolved
Comment on lines +31 to +32
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do you have a record key?
What's the cypress cloud organization url? It's hard to debug without seeing what actually was ran.

Copy link
Owner

@doug-wade doug-wade Aug 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think I can, actually. When I read the message

Your CI provider is likely not passing private environment variables to builds from forks.

I think what's happening is that the account that is doing this pr (@dougy-fresh ) and the account that owns the repository (@doug-wade ) are two different accounts, and the one doesn't get the tokens from the other. I don't think we can use cloud. Does that mean we can't use cypress at all?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

https://www.cypress.io/pricing/
There is a limited free tier.
Cypress Cloud is essentially required to do anything with CI/CD because you can't view what happened in the test run.
It looks like you got something working with cloud when running it local.
The fact that the github action run mentions extra tabs error means there is something different going on and we'd need the video recording to get an idea about it.

Disparity between local and CI run environments is very common.

@@ -6,20 +6,22 @@
"scripts": {
"build": "turbo build",
"clean": "turbo clean",
"e2e": "cypress run --browser=chrome",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i'd add --headless just to make sure it isn't using a headed version and causing issues.
There is allegedly a --headless=new to use the new version of chrome headless but it hasn't worked for me yet. Trying to find out about how it's used.

@dougy-fresh dougy-fresh force-pushed the fix-170 branch 2 times, most recently from bfbed5c to b87c8e1 Compare August 15, 2023 01:00
@doug-wade
Copy link
Owner

Here's what the test results look like when I upload it while running locally

Screenshot 2023-08-14 at 6 10 18 PM

@doug-wade
Copy link
Owner

Thanks for your help @Ginsusamurai ! These commits landed in #521

@doug-wade doug-wade closed this Dec 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

add cypress tests
3 participants