-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
fix(server): correctly include projectRoot when adding a CI project from GUI #17514
fix(server): correctly include projectRoot when adding a CI project from GUI #17514
Conversation
* fix: make vite re-run on supportFile change * chore: vite - add an example of support css * fix lachlan's remarks
Thanks for taking the time to open a PR!
|
274c3a6
to
b8cb29e
Compare
@@ -374,7 +374,7 @@ class SetupProject extends Component { | |||
_setupProject () { | |||
if (this.state.newProject) { | |||
return dashboardProjectsApi.setupDashboardProject({ | |||
projectName: this.state.projectName, | |||
projectRoot: this.props.project.path, |
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.
This is the fix - instead of using options.projectRoot
, we should just pass the projectRoot
when we call setupDashboardProject
.
Test summaryRun details
View run in Cypress Dashboard ➡️ This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard |
@lmiller1990 Have you tested this for selecting an existing project from the dashboard? This should only insert the projectId but I don't see any changes that directly touch this |
@panzarino I will try this now. |
@panzarino good catch... fixed here: 4f68416 I added some videos showing manually testing in the PR description. |
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've manually verified that this fixes the original issue.
Released in This comment thread has been locked. If you are still experiencing this issue after upgrading to |
User facing changelog
Fix a bug where you cannot add a new CI project from the Cypress launcher GUI.
Additional details
This PR targets
master
, so we can do a patch release that just bundles this fix. It will probably need this fix for CI to be green.How to reproduce:
cd packages/desktop-gui
(for example)CYPRESS_INTERNAL_ENV=production yarn cross-env TZ=America/New_York node ../../scripts/cypress open --global
projectId
incypress.json
Check out this branch and do the above to manually verify this is fixed. I also added some tests - the problem was we assume
options.projectRoot
exists, but it does not for projects added via global mode. The fix is to simply pass theprojectRoot
when adding a new project, instead of relying onoptions.projectRoot
.How has the user experience changed?
Can correctly create a CI project from the GUI.
Test: adding an existing project
existing_project.mov
Testing: adding a new project
new_project.mov
PR Tasks
cypress-documentation
?type definitions
?cypress.schema.json
?