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(dev): add Cypress and Puppeteer to GitPod #40862
Conversation
This is working as expected (on my end). To use, the workflow is:
The white-space changes appear to be in-line with our config, so I have left them. Let me know otherwise. P.S. I expect some tests to fail, because some are hard-coded to work in a 'normal' dev environment. Specifically, values like 'localhost:8000' do not work in GitPod. So, another PR would need to take a look at that. I have done some of it in this PR (and a previous), which is why |
@raisedadead Are you on the Feature Preview of GitPod? https://www.gitpod.io/docs/feature-preview/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I missed that in the conversation from the earlier PR. It works now, we may need to document this additional step.
LGTM. Will wait for @ojeytonwilliams to merge
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK - I think here is what we should do.
- I am going to land this in.
- We add some docs about enabling the feature in settings, and running tests.
- We work towards making the tests not rely on
localhost:8000
, but more generally compatible with a URL.
Hey @ShaunSHamilton , congrats on figuring this out. So, I ran into
when I tried to Assuming it's not just me, then the issue is that Gitpod is running a Docker container, but we don't have control over it. That means we may not be able to deploy the fixes shown here: cypress-io/cypress#350 Any thoughts on this? |
@ojeytonwilliams I have not seen that, this time around. Did you do anything different to the steps in the OP? (I am specifically asking about whether the issue is you did/did-not have the |
I am not quite sure about the messages above, but it's fairly possible I may have missed it because Shaun did say we can expect tests to fail. |
So, I launched Gitpod via https://gitpod.io/#https://github.com/freeCodeCamp/freeCodeCamp, waited until the client and server were both running and then ran npm run cypress:install-build-tools # picking 30 and 1, for the keyboard, though I doubt that matters!
npm run cypress:dev:run and got the same error I mentioned above. I was using Brave, not Chrome, so that might be a factor. I'll try again and report back. |
@ShaunSHamilton same error again I'm afraid. It might be my machine that's the problem, but it's happening pretty consistently. |
Thanks, for letting us know. I cannot see how it would be related to someone's PC. I would like to help debug this, later over chat. |
For future reference, in case I forget... Shaun and I tested this some more and found that the problem occurs somewhat randomly. The plan from here is to fix the port problem and then reevaluate if this annoying enough to try and fix. |
Checklist:
Update index.md
)master
branch of freeCodeCamp.(01/02/2021) - requires to be on the Feature Preview of GitPod
npm run cypress:install-build-tools
cypress:dev:run
withserver
andclient
running in different terminals (background)A DOCS PR is soon to follow
Closes #39728
P.S. I expect some tests to fail, because some are hard-coded to work in a 'normal' dev environment. Specifically, values like 'localhost:8000' do not work in GitPod. So, another PR would need to take a look at that. I have done some of it in this PR (and a previous), which is why CYPRESS_BASE_URL is in the .gitpod config