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

chore: fix test and types in server #23693

Merged
merged 2 commits into from
Sep 8, 2022
Merged

chore: fix test and types in server #23693

merged 2 commits into from
Sep 8, 2022

Conversation

lmiller1990
Copy link
Contributor

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Sep 7, 2022

Thanks for taking the time to open a PR!

@@ -166,7 +166,7 @@ export function launch (
debuggingPort: number,
args: string[] = [],
defaultBrowserEnv = {},
): LaunchedBrowser {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Return value is implicit

image

@@ -561,7 +561,7 @@ export async function open (browser: Browser, url: string, options: BrowserLaunc

debug('closing firefox')

originalBrowserKill.apply(browserInstance, args)
return originalBrowserKill.apply(browserInstance, args)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Needed to return this so the overridden kill has the correct signature (needs a return value of boolean)

@lmiller1990 lmiller1990 changed the title chore: update types chore: improve types in server Sep 7, 2022
@lmiller1990 lmiller1990 requested a review from flotwig September 7, 2022 00:20
@@ -531,12 +531,12 @@ export async function open (browser: Browser, url: string, options: BrowserLaunc

debug('launch in firefox', { url, args: launchOptions.args })

const browserInstance = await launch(browser, 'about:blank', remotePort, launchOptions.args, {
Copy link
Contributor Author

@lmiller1990 lmiller1990 Sep 7, 2022

Choose a reason for hiding this comment

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

it's not async, but we thought it was due to an incorrect stub:

https://github.com/cypress-io/cypress/pull/23693/files#diff-f9c4dee1b34838627199ffa020b3b984f10b1dcb7a3cd74a264d06823293fe42L148

In this case the erroneously stubbed value in the unit test was leading us to write incorrect code.

@lmiller1990 lmiller1990 changed the title chore: improve types in server chore: fix test and types in server Sep 7, 2022
@lmiller1990 lmiller1990 marked this pull request as ready for review September 7, 2022 03:55
@cypress
Copy link

cypress bot commented Sep 7, 2022



Test summary

39674 0 3345 0Flakiness 0


Run details

Project cypress
Status Passed
Commit 7fdb46b
Started Sep 7, 2022 4:00 AM
Ended Sep 7, 2022 4:15 AM
Duration 14:54 💡
OS Linux Debian - 11.3
Browser Multiple

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 lmiller1990 merged commit 1aa9793 into develop Sep 8, 2022
@lmiller1990 lmiller1990 deleted the firefox-types branch September 8, 2022 02:32
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.

2 participants