Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' into issue-28123
Browse files Browse the repository at this point in the history
mschile authored Dec 9, 2024
2 parents 5dd3010 + e96593b commit 33223b6
Showing 27 changed files with 374 additions and 225 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/update_v8_snapshot_cache.yml
Original file line number Diff line number Diff line change
@@ -118,11 +118,17 @@ jobs:
echo "BRANCH_NAME=update-v8-snapshot-cache-on-${{ env.BASE_BRANCH }}-${{ env.PLATFORM }}" >> $GITHUB_ENV
echo "BRANCH_EXISTS=$(git show-ref --verify --quiet refs/remotes/origin/update-v8-snapshot-cache-on-${{ env.BASE_BRANCH }}-${{ env.PLATFORM }} && echo 'true')" >> $GITHUB_ENV
shell: bash
- name: Check number of existing prs
id: check-number-of-existing-prs
run: |
echo "number_of_prs_for_branch=$(gh api '/repos/cypress-io/cypress/pulls?head=cypress-io:${{ env.BRANCH_NAME }}' --jq length)" >> $GITHUB_OUTPUT
env:
GH_TOKEN: ${{ secrets.BOT_GITHUB_ACTION_TOKEN }}
shell: bash
- name: Check need for PR or branch update
id: check-need-for-pr
run: |
echo "number_of_prs_for_branch=$(gh api '/repos/cypress-io/cypress/pulls?head=cypress-io:${{ env.BRANCH_NAME }}' --jq length)" >> $GITHUB_OUTPUT
echo "needs_pr=${{ steps.check-for-v8-snapshot-cache-changes.outputs.has_changes == 'true' && env.BRANCH_NAME != env.BASE_BRANCH && steps.check-need-for-pr.outputs.number_of_prs_for_branch == '0' }}" >> $GITHUB_OUTPUT
echo "needs_pr=${{ steps.check-for-v8-snapshot-cache-changes.outputs.has_changes == 'true' && env.BRANCH_NAME != env.BASE_BRANCH && steps.check-number-of-existing-prs.outputs.number_of_prs_for_branch == '0' }}" >> $GITHUB_OUTPUT
echo "needs_branch_update=${{ steps.check-for-v8-snapshot-cache-changes.outputs.has_changes == 'true' && env.BRANCH_EXISTS == 'true' }}" >> $GITHUB_OUTPUT
env:
GH_TOKEN: ${{ secrets.BOT_GITHUB_ACTION_TOKEN }}
4 changes: 2 additions & 2 deletions browser-versions.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"chrome:beta": "131.0.6778.33",
"chrome:stable": "131.0.6778.69",
"chrome:beta": "132.0.6834.32",
"chrome:stable": "131.0.6778.108",
"chrome:minimum": "64.0.3282.0"
}
18 changes: 17 additions & 1 deletion cli/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,23 @@
<!-- See the ../guides/writing-the-cypress-changelog.md for details on writing the changelog. -->
## 13.16.2

_Released 12/17/2024 (PENDING)_

**Bugfixes:**

- Fixed an issue where targets may hang if `Network.enable` is not implemented for the target. Addresses [#29876](https://github.com/cypress-io/cypress/issues/29876).

## 13.16.1

_Released 12/03/2024_

**Bugfixes:**

- During recorded or parallel runs, execution will fail if Cypress is unable to confirm the creation of an instance instead of skipping the spec. Addresses [#30628](https://github.com/cypress-io/cypress/issues/30628).

## 13.16.0

_Released 11/19/2024 (PENDING)_
_Released 11/19/2024_

**Features:**

2 changes: 1 addition & 1 deletion guides/writing-the-cypress-changelog.md
Original file line number Diff line number Diff line change
@@ -57,4 +57,4 @@ At the time of the release, the releaser will:
- ensure the change sections are in the correct order
- ensure that the entries are ordered by impact

Each Cypress release results in an update to the [changelog.mdx](https://github.com/cypress-io/cypress-documentation/blob/main/docs/guides/references/changelog.mdx) file in the [cypress-documentation](https://github.com/cypress-io/cypress-documentation) repository to be published on the [doc site](https://docs.cypress.io/guides/references/changelog). See [Example pull request](https://github.com/cypress-io/cypress-documentation/pull/5874) adding a new changelog section to the repository.
Each Cypress release results in an update to the [changelog.mdx](https://github.com/cypress-io/cypress-documentation/blob/main/docs/app/references/changelog.mdx) file in the [cypress-documentation](https://github.com/cypress-io/cypress-documentation) repository to be published on the [doc site](https://docs.cypress.io/guides/references/changelog). See [Example pull request](https://github.com/cypress-io/cypress-documentation/pull/5965) adding a new changelog section to the repository.
19 changes: 5 additions & 14 deletions npm/grep/README.md
Original file line number Diff line number Diff line change
@@ -51,14 +51,10 @@ Table of Contents
- [Debugging in the plugin](#debugging-in-the-plugin)
- [Debugging in the browser](#debugging-in-the-browser)
- [Examples](#examples)
- [See also](#see-also)
- [Migration guide](#migration-guide)
- [from v1 to v2](#from-v1-to-v2)
- [from v2 to v3](#from-v2-to-v3)
- [Videos & Blog Posts](#videos--blog-posts)
- [Blog posts](#blog-posts)
- [Small print](#small-print)
- [MIT License](#mit-license)

<!-- /MarkdownTOC -->

@@ -117,7 +113,7 @@ registerCypressGrep()
}
```

Installing the plugin via `setupNodeEvents()` is required to enable the [grepFilterSpecs](#grepfilterspecs) feature.
Installing the plugin via `setupNodeEvents()` is required to enable the [grepFilterSpecs](#pre-filter-specs-grepfilterspecs) feature.

## Usage Overview

@@ -320,7 +316,7 @@ describe('block with config tag', { tags: '@smoke' }, () => {})
--env grepTags=-@smoke
```

See the [cypress/integration/describe-tags-spec.js](./cypress/integration/describe-tags-spec.js) file.
See the [cypress/e2e/describe-tags-spec.js](./cypress/e2e/describe-tags-spec.js) file.

**Note:** global function `describe` and `context` are aliases and both supported by this plugin.

@@ -424,7 +420,7 @@ it('runs on deploy', { tags: 'smoke' }, () => {
This package comes with [src/index.d.ts](./src/index.d.ts) definition file that adds the property `tags` to the Cypress test overrides interface. Include this file in your specs or TS config settings. For example, you can load it using a reference comment

```js
// cypress/integration/my-spec.js
// cypress/e2e/my-spec.js
/// <reference types="@cypress/grep" />
```

@@ -559,11 +555,6 @@ To see how to debug this plugin, watch the video [Debug @cypress/grep Plugin](ht
- [cypress-grep-example](https://github.com/bahmutov/cypress-grep-example)
- [todo-graphql-example](https://github.com/bahmutov/todo-graphql-example)

## See also

- [cypress-select-tests](https://github.com/bahmutov/cypress-select-tests)
- [cypress-skip-test](https://github.com/cypress-io/cypress-skip-test)

## Migration guide

### from v1 to v2
@@ -599,5 +590,5 @@ Version >= 3 of @cypress/grep _only_ supports Cypress >= 10.

License: MIT - do anything with the code, but don't blame me if it does not work.

Support: if you find any problems with this module, email / tweet /
[open issue](https://github.com/cypress-io/cypress/issues) on Github.
Support: if you find any problems with this module,
[open issue](https://github.com/cypress-io/cypress/issues) on GitHub.
7 changes: 7 additions & 0 deletions npm/vite-dev-server/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# [@cypress/vite-dev-server-v5.2.1](https://github.com/cypress-io/cypress/compare/@cypress/vite-dev-server-v5.2.0...@cypress/vite-dev-server-v5.2.1) (2024-11-19)


### Bug Fixes

* ensure that each js file served up by vite dev server has an inline sourcemap ([#30606](https://github.com/cypress-io/cypress/issues/30606)) ([4bf8e58](https://github.com/cypress-io/cypress/commit/4bf8e585cd68e0f5bb879a960073ed30791ebc37))

# [@cypress/vite-dev-server-v5.2.0](https://github.com/cypress-io/cypress/compare/@cypress/vite-dev-server-v5.1.1...@cypress/vite-dev-server-v5.2.0) (2024-08-27)


7 changes: 7 additions & 0 deletions npm/vite-plugin-cypress-esm/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# [@cypress/vite-plugin-cypress-esm-v1.1.2](https://github.com/cypress-io/cypress/compare/@cypress/vite-plugin-cypress-esm-v1.1.1...@cypress/vite-plugin-cypress-esm-v1.1.2) (2024-12-03)


### Bug Fixes

* support multiple imports of one module with multiple lines ([#30314](https://github.com/cypress-io/cypress/issues/30314)) ([12df40e](https://github.com/cypress-io/cypress/commit/12df40ed8c1101c5c4053a1fe63c06fcd2809bc7))

# [@cypress/vite-plugin-cypress-esm-v1.1.1](https://github.com/cypress-io/cypress/compare/@cypress/vite-plugin-cypress-esm-v1.1.0...@cypress/vite-plugin-cypress-esm-v1.1.1) (2024-05-10)


Original file line number Diff line number Diff line change
@@ -2,6 +2,12 @@ export const export1 = 'export1'

export const export2 = 'export2'

export const export3 = 'export3'

export const export4 = 'export4'

export const export5 = 'export5'

// @ts-expect-error
window.sideEffect = 'Side Effect'

65 changes: 63 additions & 2 deletions npm/vite-plugin-cypress-esm/cypress/component/importSyntax.cy.ts
Original file line number Diff line number Diff line change
@@ -9,6 +9,17 @@ import { default as alias } from './fixtures/kitchenSink'
import defaultExport2, { export2 } from './fixtures/kitchenSink'
import defaultExport3, * as name2 from './fixtures/kitchenSink'
import { export1 as e1, export2 as e2 } from './fixtures/kitchenSink'
import {
export3,
export4,
} from './fixtures/kitchenSink'
import {
export3 as alias3,
export4 as alias4,
} from './fixtures/kitchenSink'
import defaultExport4, {
export5,
} from './fixtures/kitchenSink'
import './fixtures/kitchenSink'

// Examples for all syntax
@@ -19,6 +30,9 @@ describe('supports every combination of import syntax in a single file', () => {
expect(defaultExport1).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
@@ -30,6 +44,9 @@ describe('supports every combination of import syntax in a single file', () => {
expect(name1).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
@@ -38,7 +55,7 @@ describe('supports every combination of import syntax in a single file', () => {
})

it('Import { export1 } from "./kitchenSink"', () => {
expect(export1).to.deep.eq(export1)
expect(export1).to.eq('export1')
})

it('Import { export1 as alias1 } from "./kitchenSink"', () => {
@@ -56,19 +73,25 @@ describe('supports every combination of import syntax in a single file', () => {
expect(defaultExport2).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
},
})

expect(export2).to.eq(export2)
expect(export2).to.eq('export2')
})

it('Import defaultExport3, * as name2 from "./kitchenSink"', () => {
expect(defaultExport3).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
@@ -80,6 +103,9 @@ describe('supports every combination of import syntax in a single file', () => {
expect(name2).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
@@ -92,6 +118,41 @@ describe('supports every combination of import syntax in a single file', () => {
expect(e2).to.deep.eq(export2)
})

it(`import {
export3,
export4,
} from './fixtures/kitchenSink'`, () => {
expect(export3).to.deep.eq('export3')
expect(export4).to.deep.eq('export4')
})

it(`import {
export3 as alias3,
export4 as alias4,
} from './fixtures/kitchenSink'`, () => {
expect(alias3).to.deep.eq(export3)
expect(alias4).to.deep.eq(export4)
})

it(`import defaultExport4, {
export5,
} from './fixtures/kitchenSink'`, () => {
console.log(defaultExport4)
expect(defaultExport4).to.deep.eq({
export1: 'export1',
export2: 'export2',
export3: 'export3',
export4: 'export4',
export5: 'export5',
default: {
export1: 'export1',
export2: 'export2',
},
})

expect(export5).to.eq('export5')
})

it('Import "./kitchenSink"', () => {
// @ts-expect-error
expect(window.sideEffect).to.eq('Side Effect')
2 changes: 1 addition & 1 deletion npm/vite-plugin-cypress-esm/src/index.ts
Original file line number Diff line number Diff line change
@@ -120,7 +120,7 @@ export const CypressEsm = (options?: CypressEsmOptions): Plugin => {

// Ensure import comes at start of line *or* is prefixed by a space so we don't capture things like
// `Refresh.__hmr_import('')
const importRegex = /(?<=^|\s)import (.+?) from ['"](.*?)['"]/g
const importRegex = /(?<=^|\s)import ([^;'"]+?) from ['"](.*?)['"]/g

return code.replace(
importRegex,
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cypress",
"version": "13.15.2",
"version": "13.16.1",
"description": "Cypress is a next generation front end testing tool built for the modern web",
"private": true,
"scripts": {

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 3 additions & 1 deletion packages/errors/src/errors.ts
Original file line number Diff line number Diff line change
@@ -175,7 +175,7 @@ export const AllCypressErrors = {
${fmt.highlightSecondary(arg1.response)}
Because you passed the ${fmt.flag(`--parallel`)} flag, this run cannot proceed because it requires a valid response from our servers.
Because you passed the ${fmt.flag(`--parallel`)} flag, this run cannot proceed since it requires a valid response from our servers.
${fmt.listFlags(arg1.flags, {
group: '--group',
@@ -188,6 +188,8 @@ export const AllCypressErrors = {
${fmt.highlightSecondary(arg1.response)}
Because you passed the ${fmt.flag(`--record`)} flag, this run cannot proceed since it requires a valid response from our servers.
${fmt.listFlags(arg1.flags, {
group: '--group',
ciBuildId: '--ciBuildId',
2 changes: 1 addition & 1 deletion packages/example/package.json
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@
},
"devDependencies": {
"cross-env": "6.0.3",
"cypress-example-kitchensink": "3.1.1",
"cypress-example-kitchensink": "3.1.2",
"gh-pages": "5.0.0",
"gulp": "4.0.2",
"gulp-clean": "0.4.0",
Loading

0 comments on commit 33223b6

Please sign in to comment.