Skip to content

Commit

Permalink
misc: Remove 'Alternatively you can use CommonJS syntax' comment from…
Browse files Browse the repository at this point in the history
… scaffolded component supportFile (#30738)

* Remove 'Alternatively you can use CommonJS syntax' comment from scaffolded ct supportFile

* changelog entry
  • Loading branch information
jennifer-shehane authored Dec 11, 2024
1 parent 73de0a8 commit 17639cb
Show file tree
Hide file tree
Showing 24 changed files with 4 additions and 103 deletions.
4 changes: 4 additions & 0 deletions cli/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ _Released 12/17/2024 (PENDING)_
- Updated Firefox `userChrome.css` to correctly hide the toolbox during headless mode. Addresses [#30721](https://github.com/cypress-io/cypress/issues/30721).
- Fixed an issue loading the `cypress.config.ts` file with Node.js version `22.12.0`. Addresses [#30715](https://github.com/cypress-io/cypress/issues/30715).

**Misc:**

- Removed a comment from the scaffolded `supportFile` for component tests around CommonJS syntax. Addresses [#23287](https://github.com/cypress-io/cypress/issues/23287).

**Dependency Updates:**

- Updated `chai` from `4.2.0` to `4.5.0`. Addressed in [#30737](https://github.com/cypress-io/cypress/pull/30737).
Expand Down
17 changes: 0 additions & 17 deletions packages/driver/cypress/support/e2e.js
Original file line number Diff line number Diff line change
@@ -1,18 +1 @@
// ***********************************************************
// This example support/e2e.js is processed and
// loaded automatically before your other test files.
//
// This is a great place to put global configuration and
// behavior that modifies Cypress.
//
// You can change the location of this file or turn off
// automatically serving support files with the
// 'supportFile' configuration option.
//
// You can read more here:
// https://on.cypress.io/guides/configuration#section-global
// ***********************************************************

// Alternatively you can use CommonJS syntax:
// require("./commands")
require('./defaults')
6 changes: 0 additions & 6 deletions packages/scaffold-config/src/supportFile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,6 @@ export function supportFileE2E (language: CodeLanguage['type']) {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
`
}

Expand All @@ -45,9 +42,6 @@ export function supportFileComponent (language: CodeLanguage['type'], mountModul
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
`

const exampleUse = dedent`
Expand Down
21 changes: 0 additions & 21 deletions packages/scaffold-config/test/unit/supportFile.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from '${mountModule}'
Cypress.Commands.add('mount', mount)
Expand Down Expand Up @@ -61,9 +58,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from '${mountModule}'
// Augment the Cypress namespace to include type definitions for
Expand Down Expand Up @@ -111,9 +105,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from '${mountModule}'
Cypress.Commands.add('mount', mount)
Expand Down Expand Up @@ -145,9 +136,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from '${mountModule}'
// Augment the Cypress namespace to include type definitions for
Expand Down Expand Up @@ -195,9 +183,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from '${mountModule}'
// Augment the Cypress namespace to include type definitions for
Expand Down Expand Up @@ -244,9 +229,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from 'cypress/svelte'
Cypress.Commands.add('mount', mount)
Expand Down Expand Up @@ -278,9 +260,6 @@ describe('supportFileComponent', () => {
// Import commands.js using ES2015 syntax:
import './commands'
// Alternatively you can use CommonJS syntax:
// require('./commands')
import { mount } from 'cypress/svelte'
// Augment the Cypress namespace to include type definitions for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/angular'

// Augment the Cypress namespace to include type definitions for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/vue2'

Cypress.Commands.add('mount', mount)
Expand Down
3 changes: 0 additions & 3 deletions system-tests/projects/no-specs/cypress/support/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/react'

Cypress.Commands.add('mount', mount)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,3 @@

// Import commands.js using ES2015 syntax:
import '@cypress/code-coverage/support'
// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/vue'

Cypress.Commands.add('mount', mount)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/react'

Cypress.Commands.add('mount', mount)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@
// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

import { mount } from 'cypress/react'

// Augment the Cypress namespace to include type definitions for
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
3 changes: 0 additions & 3 deletions system-tests/projects/ts-proj-4-5/cypress/support/e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
// import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
3 changes: 0 additions & 3 deletions system-tests/projects/ts-proj-5/cypress/support/e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
// import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')
3 changes: 0 additions & 3 deletions system-tests/projects/ts-proj/cypress/support/e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,3 @@

// Import commands.js using ES2015 syntax:
import './commands'

// Alternatively you can use CommonJS syntax:
// require('./commands')

3 comments on commit 17639cb

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 17639cb Dec 11, 2024

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 build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/13.16.2/linux-x64/develop-17639cb364b8cc3a2f7debcdae220fa899559c94/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 17639cb Dec 11, 2024

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 arm64 version of the Test Runner.

Learn more about this pre-release build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/13.16.2/linux-arm64/develop-17639cb364b8cc3a2f7debcdae220fa899559c94/cypress.tgz

@cypress-bot
Copy link
Contributor

@cypress-bot cypress-bot bot commented on 17639cb Dec 11, 2024

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 build at https://on.cypress.io/advanced-installation#Install-pre-release-version

Run this command to install the pre-release locally:

npm install https://cdn.cypress.io/beta/npm/13.16.2/darwin-x64/develop-17639cb364b8cc3a2f7debcdae220fa899559c94/cypress.tgz

Please sign in to comment.