Skip to content

Commit

Permalink
fix: error regression - unexpected ANSI color chars shown on Firefox …
Browse files Browse the repository at this point in the history
…warning message about chromeWebSecurity (#20512)
  • Loading branch information
davidmunechika committed Mar 8, 2022
1 parent 2d81628 commit 047aefc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 2 additions & 1 deletion packages/server/lib/project-base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ import * as settings from './util/settings'
import specsUtil from './util/specs'
import system from './util/system'
import Watchers from './watchers'
import stripAnsi from 'strip-ansi'

import type { LaunchArgs } from './open_project'

Expand Down Expand Up @@ -704,7 +705,7 @@ export class ProjectBase<TServer extends ServerE2E | ServerCt> extends EE {

return {
...browser,
warning: browser.warning || errors.getMsgByType('CHROME_WEB_SECURITY_NOT_SUPPORTED', browser.name),
warning: browser.warning || stripAnsi(errors.getMsgByType('CHROME_WEB_SECURITY_NOT_SUPPORTED', browser.name)),
}
})
}
Expand Down
4 changes: 1 addition & 3 deletions packages/server/test/unit/project_spec.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
const { theme } = require('@packages/errors/src/errTemplate')

require('../spec_helper')

const mockedEnv = require('mocked-env')
Expand Down Expand Up @@ -248,7 +246,7 @@ describe('lib/project-base', () => {
family: 'some-other-family',
name: 'some-other-name',
warning: `\
Your project has set the configuration option: ${theme.yellow('chromeWebSecurity')} to ${theme.blue('false')}
Your project has set the configuration option: chromeWebSecurity to false
This option will not have an effect in Some-other-name. Tests that rely on web security being disabled will not run as expected.\
`,
Expand Down

3 comments on commit 047aefc

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 047aefc Mar 8, 2022

Choose a reason for hiding this comment

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

Circle has built the linux x64 version of the Test Runner.

Learn more about this pre-release platform-specific build at https://on.cypress.io/installing-cypress#Install-pre-release-version.

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/9.5.2/linux-x64/develop-047aefc4ba0b2eeb60b869e8ac2fab1322034fa8/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 047aefc Mar 8, 2022

Choose a reason for hiding this comment

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

Circle has built the darwin x64 version of the Test Runner.

Learn more about this pre-release platform-specific build at https://on.cypress.io/installing-cypress#Install-pre-release-version.

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/9.5.2/darwin-x64/develop-047aefc4ba0b2eeb60b869e8ac2fab1322034fa8/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 047aefc Mar 8, 2022

Choose a reason for hiding this comment

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

Circle has built the win32 x64 version of the Test Runner.

Learn more about this pre-release platform-specific build at https://on.cypress.io/installing-cypress#Install-pre-release-version.

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/9.5.2/win32-x64/develop-047aefc4ba0b2eeb60b869e8ac2fab1322034fa8/cypress.tgz

Please sign in to comment.