Commit Graph

498 Commits

Author SHA1 Message Date
Jim Hays
34c8b1f884 refactor: Spellcheck (#27964)
Co-authored-by: Matthew Schile <mschile@cypress.io>
2023-10-11 10:06:10 -04:00
Chris Breiding
cbf266c05e fix: Include run.stats.skipped in results (#27695)
Co-authored-by: Matt Schile <mschile@cypress.io>
2023-08-30 15:30:23 -04:00
Bill Glesias
1c6a2e130e BREAKING: add breaking changes/deprecations to cypress dependencies, such as typescript and node that may affect users moving forward on v13 (#27642) 2023-08-25 10:10:02 -04:00
Ryan Manuel
bb7b7c0657 Merge branch 'develop' into release/13.0.0 2023-08-25 09:02:04 -05:00
rewento
4288634e0b fix: Properly type Cypress and Chai globals as properties of the global object (#27540)
* Minor modifications to CLI types so that Cypress and Chai globals are correctly declared not only to be in the global scope but also to be in properties of globalThis, which they are. The change allows composers to explicitly access them through globalThis (e.g., 'globalThis.cy.mount', 'globalThis.expect'). The current typing prohibits this by incorrectly declaring that the objects in question are held in local variables of the global scope rather than in properties of globalThis.

* Reverted a change from previous commit

* fix: Properly type Cypress and Chai globals as properties of the global object

* fix: Properly type Cypress and Chai globals as properties of the global object

* fix: Properly type Cypress and Chai globals as properties of the global object

* update changelog

* fix changelog entry

* fix changelog entry

---------

Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
Co-authored-by: Chris Breiding <chrisbreiding@gmail.com>
2023-08-24 11:22:04 -04:00
Matt Schile
c1a8004924 chore: added support for --runner-ui and --no-runner-ui cli options (#27582) 2023-08-18 16:32:53 -06:00
Matt Schile
ea238360c2 chore: hide reporter when protocol is enabled (#27482) 2023-08-16 12:07:09 -06:00
Bill Glesias
8102a09200 Merge branch 'develop' of https://github.com/cypress-io/cypress into merge-develop-into-13 2023-08-04 16:27:38 -04:00
Bill Glesias
68f8f99a9d chore: update node types from v14 to v16 latest to be current (no 16.16.0 types exist). Fixes types issues with webpack upgrade. (#27425)
chore: bump the Typescript minimum version in the CLI from 3.4 to 3.9
2023-08-01 09:16:49 -04:00
Chris Breiding
069d3b399c breaking: Normalize results from module api, after:run, and after:spec (#27230) 2023-07-31 14:37:11 -04:00
Matt Schile
0e936c5222 Merge branch 'develop' into mschile/v13_merge_develop 2023-07-14 13:41:53 -06:00
Jordan Shehane
d56b628b30 fix: Fix Typescript types for screenshot command. (#27130)
Co-authored-by: Mike Plummer <mikep@cypress.io>
Co-authored-by: Mike Plummer <mike-plummer@users.noreply.github.com>
2023-07-07 09:08:18 -05:00
Ryan Manuel
51fa53ca56 Merge branch 'develop' into release/13.0.0 2023-06-30 10:08:27 -05:00
Ioanna Moraiti
df437cdb0a fix: AttemptResult object (#26569)
Co-authored-by: Mike Plummer <mikep@cypress.io>
Co-authored-by: Mike Plummer <mike-plummer@users.noreply.github.com>
Co-authored-by: Lachlan Miller <lachlan.miller.1990@outlook.com>
2023-06-30 08:54:10 -05:00
Bill Glesias
d68a3aa002 Merge branch 'develop' into chore/develop-into-release-13 2023-06-29 14:32:24 -04:00
Chris Breiding
e0d814c247 fix: Handle more argument types in privileged commands (#27166) 2023-06-29 12:26:30 -04:00
Bill Glesias
aa8972b07d Merge branch 'develop' into chore/develop-into-release-13 2023-06-22 12:42:18 -04:00
Bill Glesias
8607e65d1a breaking: remove the shouldUploadVideoOnPass configuration (#27010)
* breaking: remove the shouldUploadVideoOnPass configuration

* run ci
2023-06-21 11:37:29 -04:00
Bill Glesias
9580dc2e35 breaking: default video configuration option to false (#27008)
* chore: update darwin v8 snapshot

* BREAKING CHANGE: set video to false by default (system tests need updating).

* Update cli/CHANGELOG.md

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>

* chore: update type comments

* chore: update protocol snapshot

* run ci

* run ci

* set video to true for chrome browser crash test

* chore: put in workaround for failing system test spec to be fixed in 27062

* chore: allow retries on actionability tests to be at least one retry as the CI tests run faster without video on

* chore: fix flaky navigation test where done is called multiple times almsot always, but sometimes throws an error

---------

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
2023-06-20 13:21:39 -04:00
Matt Schile
d76d4e1ecf chore: 12.15.0 release (#27087) 2023-06-20 11:21:50 -05:00
Chris Breiding
89f0fb6465 chore: internal refactor of privileged commands (#27060) 2023-06-16 10:45:53 -04:00
Matt Henkes
5f93282658 breaking: Remove deprecated nodeVersion configuration option (#27059)
* feat: breaking remove nodeVersion option

* changelog, ts fix

* Apply suggestions from code review

Co-authored-by: Mike McCready <66998419+MikeMcC399@users.noreply.github.com>

---------

Co-authored-by: Mike McCready <66998419+MikeMcC399@users.noreply.github.com>
2023-06-16 09:36:20 -05:00
Preston Goforth
71c5b864ea feat: Selective CSP header stripping from HTTPResponse (#26483)
* feat: Selective CSP header directive stripping from HTTPResponse
- uses `stripCspDirectives` config option

* feat: Selective CSP header directive permission from HTTPResponse
- uses `experimentalCspAllowList` config option

* Address Review Comments:
- Add i18n for `experimentalCspAllowList`
- Remove PR link in changelog
- Fix docs link in changelog
- Remove extra typedef additions
- Update validation error message and snapshot
- Fix middleware negated conditional

* chore: refactor driver test into system tests to get better test
coverage on experimentalCspAllowList options

* Address Review Comments:
- Remove legacyOption for `experimentalCspAllowList`
- Update App desc for `experimentalCspAllowList` to include "Content-Security-Policy-Report-Only"
- Modify CHANGELOG wording
- Specify “never” overrideLevel
- Remove unused validator (+2 squashed commits)
- Add "Addresses" note in CHANGELOG to satisfy automation
- Set `canUpdateDuringTestTime` to `false` to prevent confusion

* chore: Add `frame-src` and `child-src` to conditional CSP directives

* chore: Rename `isSubsetOf` to `isArrayIncludingAny`

* chore: fix CLI linting types

* chore: fix server unit tests

* chore: fix system tests within firefox and webkit

* chore: add form-action test

* chore: update system test snapshots

* chore: skip tests in webkit due to form-action flakiness

* chore: Move 'sandbox' and 'navigate-to' into `unsupportedCSPDirectives`
- Add additional system tests
- Update snapshots and unit test

* chore: update system test snapshots

* chore: fix system tests

* chore: do not run csp tests within firefox or webkit due to flake issues in CI

* chore: attempt to increase intercept delay to avoid race condition

* chore: update new snapshots with video defaults work

* chore: update changelog

---------

Co-authored-by: Bill Glesias <bglesias@gmail.com>
Co-authored-by: Matt Schile <mschile@cypress.io>
2023-06-14 14:54:52 -05:00
Bill Glesias
98a0f4f6ba Merge branch 'develop' into feat/protocol 2023-06-13 17:17:44 -04:00
Bill Glesias
6b7683e483 feat: allow users to pass true to videoCompression config and only a… (#26810)
* chore: allow users to pass true to videoCompression config and only allow valudes 1-51 inclusively to be passed in

* run ci

* chore: allow zero to be option for CRF as we will coerve it to false and skip compression to have a lossless video, which has the same effect

* Update cli/CHANGELOG.md

* chore: update videoCompression types

* chore: update changelog

* Update cli/CHANGELOG.md

* Update cli/types/cypress.d.ts

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>

* Update packages/config/src/validation.ts

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>

* chore: update config snapshots

* Update packages/config/test/validation.spec.ts

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>

* chore: add system test on videoCompression=true coersion

* chore: document 0 as being false and not a valid CRF option for cypress video compression and make CRF valid values 1-51

* chore: fix types

* chore: fix types

* chore: fix change to log as feature and not bugfix

* chore: fix server side unit tests

---------

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
2023-06-08 15:56:12 -04:00
Matt Schile
0db0387a48 chore: adding snapshots to the log:added/changed (#26757) 2023-05-17 19:48:39 -06:00
Adam Stone-Lord
189cd923f7 chore: use resolve-package-path to resolve installed dependency versions more reliably (#26033) 2023-03-08 16:46:59 -05:00
Lachlan Miller
1d3aab9d70 feat: Public API for CT Framework Definitions (#25780)
* chore: rework component onboarding in launchpad (#25713)

* chore: refactoring and types

* rework source of frameworks

* revert rename

* fix tests

* fix more tests

* types

* update code

* use same public API internally

* rename interfaces

* rename

* work on dev server api

* fix types

* fix test

* attempt to support getDevServerConfig

* tests

* add function to define framework [skip ci]

* rework a lot of types

* fix test

* update tests and types

* refactor

* revert changes

* lint

* fix test

* revert

* remove

* add "community" label [skip ci]

* refactor

* types

* lint

* fix bug

* update function name

* address feedback

* improve types with Pick

* refactor using type guard

* correct label

---------

Co-authored-by: Zachary Williams <ZachJW34@gmail.com>

* chore: typing error

* feat: scan for 3rd party ct plugins (#25749)

* chore: refactoring and types

* rework source of frameworks

* revert rename

* fix tests

* fix more tests

* types

* update code

* use same public API internally

* rename interfaces

* rename

* work on dev server api

* fix types

* fix test

* attempt to support getDevServerConfig

* tests

* add function to define framework [skip ci]

* rework a lot of types

* fix test

* update tests and types

* refactor

* revert changes

* lint

* fix test

* revert

* remove

* add "community" label [skip ci]

* refactor

* types

* lint

* fix bug

* update function name

* address feedback

* feat: scan for 3rd party ct plugins

* add e2e test

* unit tests [run ci]

* tweak resolution

* rebase, address comments

* fix windows paths

* remove .gitignore

* fix test

---------

Co-authored-by: Lachlan Miller <lachlan.miller.1990@outlook.com>

* lint config

* spacing

* try fix race cond

* fix import error

* build binary

* try update snapshot

* try using require

* support namespaced definitions (#25804)

* remove category

* add icon prop

* support esm -> cjs compiled typescript

* fix test

* misc: add CTA footer to launchpad framework dropdown (#25831)

* remove test project dependencies

* rebase

* windows

* windows again

* add changelog entry

* changelog

* revert workflow

* remove worklfow

---------

Co-authored-by: Zachary Williams <ZachJW34@gmail.com>
Co-authored-by: Adam Stone-Lord <adams@cypress.io>
2023-02-21 17:43:20 +10:00
Bill Glesias
9e059d087f feat: support host only cookies (#25853)
* feat: allow setCookie API to take a hostOnly option

* chore: add jsdoc/typescript description to render to users

* chore: add changelog entry

* [run ci]

* chore: fix types

* chore: fix cookie login tests

* chore: update e2e cookie system tests

* [run ci]

* chore: fix cookie command tests. localhost cookies are calculated as hostOnly, which is consistent with how cypress works today

* chore: fix system tests for cookies.

* [run ci]

* chore: fix system tests

* chore: skip hostOnly assertions in webkit (for now)

* [run ci]

* chore: add property definitions to setCookieOptions

* [run ci]

* chore: add comments to hostOnly prop in firefox when setting a cookie
2023-02-17 17:35:04 -05:00
Podles
5fb2167bb4 fix: Fix type definitions for cy.reload() (#25779)
Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
2023-02-16 13:43:55 -06:00
Blue F
a11e266b8b feat: add Cypress.Commands.overwriteQuery (#25674)
* feat: add Cypress.Commands.overwriteQuery

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
Co-authored-by: Zach Bloomquist <git@chary.us>
2023-02-13 11:24:56 -08:00
Chris Breiding
41512c416a feat: Bundle cy.origin() dependencies at runtime (#25626)
Co-authored-by: cypress-bot[bot] <2f0651858c6e38e0+cypress-bot[bot]@users.noreply.github.com>
Co-authored-by: Ryan Manuel <ryanm@cypress.io>
2023-02-13 11:59:29 -05:00
Alejandro Estrada
19e091d0bc feat: add --auto-cancel-after-failures flag (#25237)
Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
Co-authored-by: Matt Schile <mschile@cypress.io>
Co-authored-by: Ryan Pei <ryanppei@gmail.com>
Co-authored-by: Emily Rohrbough <emilyrohrbough@yahoo.com>
2023-02-10 10:32:54 -06:00
Matt Schile
beb411f3f4 fix: test:after:run passes the runnable (#25678) 2023-02-02 08:17:25 -06:00
Blue F
094e3d03cc feat: Add 'type' option to .as to store aliases by value (#25251)
* feat: Add 'type' option to `.as` to store aliases by value

Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
2023-01-24 08:02:45 -08:00
Matt Schile
d1dc1258ea fix: improve memory management for chromium-based browsers (#25462) 2023-01-18 15:35:57 -07:00
Bill Glesias
d470f59ea2 feat: experimental skip domain injection (#25307)
* feat: set up experimentalUseDefaultDocumentDomain to disallow document.domain overwritting

* use default domain around experimentalUseDefaultDocumentDomain in main iframe and spec bridge iframes. Also adapt CORS policy to use same-origin if experimental flag is set

* run ci

* fix: add insertion of experimental flag where is was needed/missing

* chore: add system test to exercise experimental flag for expected behavior

* fix: fix issues with template updates to conform to squirrelly v7

* fix: update config tests to include new experimental flag

* run ci

* fix: trailing whitespace [run ci]

* chore: update snapshot

* run ci

* fix: update proxy unit tests to account for experimentalUseDefaultDocumentDomain

* run ci

* fix: Allow component tests with special characters in filepath (#25299)

feat: cut over experimental flag to take list of known problematic domains via string/glob pattern

run ci

chore: update system test and fix broken config

* fix: fix server unit and integration tests. integration tests should no longer use google to test against injection as we do not inject document.domain on google domains

* run ci

* run ci

* fix: server integration tests where google documents are expected to receive document.domain injection. Kept test same by changing URL

* run ci

* fix: update server test with mssing unupdated assertions

* run ci

* fix: turn off experimental flag by default while recommending sane defaults to users to configure

* run ci

* chore: fix typings [run ci]

* run ci

* chore: make experiment an e2e option only

* run ci

* chore: address comments in code review

* chore: rename experimentalUseDefaultDocumentDomain to experimentalSkipDomainInjection

* fix regression in shouldInjectionDocumentDomain utility function and add unit tests

* run ci

* chore: rename documentSuperDomainIfExists to superDomain [run ci]

* chore: address comments from code review

* chore: just pass opts through to policyForDomain

* run ci

Co-authored-by: Mike Plummer <mike-plummer@users.noreply.github.com>
2023-01-09 10:00:05 -05:00
Wojciech Szućko
acc61d8bd2 feat: add currentRetry to Cypress API (#25297)
Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
Co-authored-by: Emily Rohrbough <emilyrohrbough@yahoo.com>
2023-01-03 11:41:31 -06:00
Mike Plummer
e34adddbed fix: Add missing filter parameter to nextUntil command (#25167) 2022-12-15 15:29:42 -06:00
Emily Rohrbough
4e82100303 fix: update custom-query on links to match custom-command syntax (#25092) 2022-12-09 15:57:29 -06:00
Chris Breiding
fc43cecdad feat: Add cy.getAllCookies() and cy.clearAllCookies() (#25012) 2022-12-08 13:12:32 -05:00
Emily Rohrbough
797c8f8d77 chore: update session api types & exposed global helpers (#24980)
Co-authored-by: Matt Schile <mschile@cypress.io>
Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
2022-12-06 08:19:39 -06:00
Emily Rohrbough
afc5e030af feat(12): change testIsolation values from on/off to true/false (#24935)
* feat(12): change testIsolation values from on/off to true/false

* missed

* Update cli/types/cypress.d.ts

Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>

Co-authored-by: Matt Henkes <mjhenkes@gmail.com>
Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
2022-12-02 10:29:21 -06:00
Emily Rohrbough
05530ce531 chore(12): merge develop into release/12.0.0 (#24927)
Co-authored-by: Lachlan Miller <lachlan.miller.1990@outlook.com>
Co-authored-by: Mark Noonan <mark@cypress.io>
Co-authored-by: Matt Henkes <mjhenkes@gmail.com>
Co-authored-by: Mike Plummer <mike-plummer@users.noreply.github.com>
Co-authored-by: Zach Bloomquist <git@chary.us>
Co-authored-by: Chris Breiding <chrisbreiding@users.noreply.github.com>
Co-authored-by: Zachary Williams <ZachJW34@gmail.com>
Co-authored-by: Feng Yu <abcfy2@users.noreply.github.com>
2022-12-01 19:33:44 -06:00
Matt Schile
98efdf45b3 feat: Added experimentalOriginDependencies to gate dependencies support within cy.origin (#24931)
* adding experimentalOriginDependencies flag

* update system tests
2022-12-01 15:40:05 -06:00
Blue F
8ff38cdb01 feat: Create public Cypress.ensure API for use with custom queries (#24697)
* fix: Improve TypeScript support for custom queries

* Typo fix

* Fix TS more

* Move 'ensures' off of cy and onto Cypress

* Type fixes

* One missed replacement

* Test fixes

* Properly pass in  to ensureRunnable

* Add .eslintignores to quiet down warnings

* Review feedback

* Update cli/types/cypress.d.ts

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>

Co-authored-by: Emily Rohrbough <emilyrohrbough@users.noreply.github.com>
2022-11-29 09:34:34 -06:00
Emily Rohrbough
83f8997532 chore(v12): test isolation GA cleanup (#24736)
Co-authored-by: Matt Henkes <mjhenkes@gmail.com>
Closes undefined
2022-11-29 08:30:14 -06:00
Chris Breiding
27b0f2186f fix: Use hostname as default domain for cookie commands (#24692)
BREAKING CHANGE: Cookie commands now use the the hostname and not the superdomain for the domain by default. This may affect what cookies are returned/set/cleared by cookie commands.
2022-11-23 09:54:09 -05:00
Emily Rohrbough
5f56670051 chore(12): merge in develop (#24783)
Co-authored-by: Ben M <benm@cypress.io>
Co-authored-by: Dariusz Czajkowski <darek@darek.dev>
Co-authored-by: Ryan Manuel <ryanm@cypress.io>
Co-authored-by: Adam Stone <adams@cypress.io>
2022-11-23 07:55:29 -06:00
BlueWinds
286bd9dac1 Merge remote-tracking branch 'origin/develop' into update-release-12 2022-11-22 08:57:02 -08:00