Bump cypress@13.3.0 (#162383)

## Summary

Bump Cypress-related dependencies to the latest versions and update
`renovate.json` to do it automatically in the future

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Gloria Hornero <gloria.hornero@elastic.co>
This commit is contained in:
Patryk Kopyciński 2023-10-01 08:55:01 +00:00 committed by GitHub
parent ba64b7cfdb
commit 924664fc79
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
16 changed files with 78 additions and 97 deletions

View file

@ -28,8 +28,8 @@ steps:
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 120
parallelism: 6
timeout_in_minutes: 60
parallelism: 8
retry:
automatic:
- exit_status: '*'
@ -40,7 +40,7 @@ steps:
agents:
queue: n2-4-spot
depends_on: build
timeout_in_minutes: 120
timeout_in_minutes: 60
parallelism: 1
retry:
automatic: false

View file

@ -79,7 +79,7 @@
},
"resolutions": {
"**/@hello-pangea/dnd": "16.2.0",
"**/@types/node": "18.17.1",
"**/@types/node": "18.17.5",
"**/@typescript-eslint/utils": "5.62.0",
"**/chokidar": "^3.5.3",
"**/globule/minimatch": "^3.1.2",
@ -1361,7 +1361,7 @@
"@types/multistream": "^4.1.0",
"@types/mustache": "^0.8.31",
"@types/nock": "^10.0.3",
"@types/node": "18.17.1",
"@types/node": "18.17.5",
"@types/node-fetch": "2.6.4",
"@types/node-forge": "^1.3.1",
"@types/nodemailer": "^6.4.0",
@ -1461,13 +1461,13 @@
"cssnano": "^5.1.12",
"cssnano-preset-default": "^5.2.12",
"csstype": "^3.0.2",
"cypress": "^12.17.4",
"cypress-axe": "^1.4.0",
"cypress": "^13.3.0",
"cypress-axe": "^1.5.0",
"cypress-file-upload": "^5.0.8",
"cypress-multi-reporters": "^1.6.3",
"cypress-react-selector": "^3.0.0",
"cypress-real-events": "^1.8.1",
"cypress-recurse": "^1.35.1",
"cypress-real-events": "^1.10.3",
"cypress-recurse": "^1.35.2",
"date-fns": "^2.29.3",
"debug": "^2.6.9",
"delete-empty": "^2.0.0",

View file

@ -256,11 +256,8 @@
},
{
"groupName": "cypress",
"matchPackageNames": [
"eslint-plugin-cypress"
],
"matchPackagePatterns": [
"^cypress"
"cypress"
],
"reviewers": [
"Team:apm",

View file

@ -22,7 +22,6 @@ export default defineCypressConfig({
viewportHeight: 1800,
viewportWidth: 1440,
video: true,
videoUploadOnPasses: false,
screenshotOnRunFailure: true,
retries: {
runMode: 1,

View file

@ -64,7 +64,7 @@ export async function cypressTestRunner({ getService }: FtrProviderContext) {
const res = await cypressExecution({
...cypressCliArgs,
project: cypressProjectPath,
browser: 'chrome',
browser: 'electron',
config: {
e2e: {
baseUrl: kibanaUrlWithoutAuth,

View file

@ -46,7 +46,12 @@ async function ftrConfig({ readConfigFile }: FtrConfigProviderContext) {
const result = await cypressTestRunner(ftrProviderContext);
// set exit code explicitly if at least one Cypress test fails
if (result && (result.status === 'failed' || result.totalFailed > 0)) {
if (
result &&
((result as CypressCommandLine.CypressFailedRunResult)?.status ===
'failed' ||
(result as CypressCommandLine.CypressRunResult)?.totalFailed)
) {
process.exitCode = 1;
}
},

View file

@ -20,7 +20,6 @@ export default defineCypressConfig({
viewportHeight: 1800,
viewportWidth: 1440,
video: false,
videoUploadOnPasses: false,
screenshotOnRunFailure: false,
retries: {
runMode: 1,

View file

@ -25,7 +25,12 @@ async function testRunner(ftrProviderContext: FtrProviderContext) {
cypressExecution: cypress.run,
});
if (result && (result.status === 'failed' || result.totalFailed > 0)) {
if (
result &&
((result as CypressCommandLine.CypressFailedRunResult)?.status ===
'failed' ||
(result as CypressCommandLine.CypressRunResult)?.totalFailed)
) {
process.exit(1);
}
}

View file

@ -20,7 +20,6 @@ export default defineCypressConfig({
viewportHeight: 1800,
viewportWidth: 1440,
video: false,
videoUploadOnPasses: false,
screenshotOnRunFailure: false,
retries: {
runMode: 1,

View file

@ -22,8 +22,12 @@ async function ftrConfigRun({ readConfigFile }: FtrConfigProviderContext) {
async function testRunner(ftrProviderContext: FtrProviderContext) {
const result = await cypressTestRunner({ ftrProviderContext, cypressExecution: cypress.run });
if (result && (result.status === 'failed' || result.totalFailed > 0)) {
process.exit(1);
if (
result &&
((result as CypressCommandLine.CypressFailedRunResult)?.status === 'failed' ||
(result as CypressCommandLine.CypressRunResult)?.totalFailed)
) {
process.exitCode = 1;
}
}

View file

@ -446,7 +446,9 @@ ${JSON.stringify(cyCustomEnv, null, 2)}
renderSummaryTable(results as CypressCommandLine.CypressRunResult[]);
const hasFailedTests = _.some(
results,
(result) => result?.status === 'finished' && result.totalFailed > 0
(result) =>
(result as CypressCommandLine.CypressFailedRunResult)?.status === 'failed' ||
(result as CypressCommandLine.CypressRunResult)?.totalFailed
);
if (hasFailedTests) {
throw createFailError('Not all tests passed');

View file

@ -278,7 +278,6 @@ export function renderSummaryTable(results: CypressCommandLine.CypressRunResult[
const parsedResults = _.reduce(
results,
(acc: CypressCommandLine.CypressRunResult, result) => {
acc.status = result.status;
acc.startedTestsAt =
acc.startedTestsAt && new Date(result.startedTestsAt) > new Date(acc.startedTestsAt)
? acc.startedTestsAt
@ -358,12 +357,8 @@ export function renderSummaryTable(results: CypressCommandLine.CypressRunResult[
_.each(runs, (run) => {
const { spec, stats } = run;
const ms = durationInMinutes(stats.duration);
const formattedSpec = formatPath(spec.relativeToCommonRoot, getWidth(table2, 1));
if (run.skippedSpec) {
return table2.push(['-', formattedSpec, color('SKIPPED', 'gray'), '-', '-', '-', '-', '-']);
}
const ms = durationInMinutes(stats?.duration ?? 0);
const formattedSpec = formatPath(spec.relative, getWidth(table2, 1));
return table2.push([
formatSymbolSummary(stats.failures),

View file

@ -262,21 +262,19 @@ describe(`Detections : Page Filters`, { tags: ['@ess', '@brokenInServerless'] },
});
it(`URL is updated when filters are updated`, () => {
cy.on('url:changed', (urlString) => {
const NEW_FILTERS = DEFAULT_DETECTION_PAGE_FILTERS.map((filter) => {
return {
...filter,
selectedOptions: filter.title === 'Severity' ? ['high'] : filter.selectedOptions,
};
});
const expectedVal = encode(formatPageFilterSearchParam(NEW_FILTERS));
expect(urlString).to.contain.text(expectedVal);
});
openPageFilterPopover(1);
cy.get(OPTION_SELECTABLE(1, 'high')).should('be.visible');
cy.get(OPTION_SELECTABLE(1, 'high')).click({});
closePageFilterPopover(1);
const NEW_FILTERS = DEFAULT_DETECTION_PAGE_FILTERS.map((filter) => {
return {
...filter,
selectedOptions: filter.title === 'Severity' ? ['high'] : filter.selectedOptions,
};
});
const expectedVal = encode(formatPageFilterSearchParam(NEW_FILTERS));
cy.url().should('include', expectedVal);
});
it(`Filters are restored from localstorage when user navigates back to the page.`, () => {

View file

@ -70,35 +70,14 @@ describe('Open timeline', { tags: ['@brokenInServerless', '@ess'] }, () => {
openTimelineById(this.timelineId);
});
it('should open a modal', () => {
it('should display timeline info', () => {
cy.get(OPEN_TIMELINE_MODAL).should('be.visible');
});
it('should display timeline info - title', () => {
cy.contains(getTimeline().title).should('exist');
});
it('should display timeline info - description', () => {
cy.get(TIMELINES_DESCRIPTION).last().should('have.text', getTimeline().description);
});
it('should display timeline info - pinned event count', () => {
cy.get(TIMELINES_PINNED_EVENT_COUNT).last().should('have.text', '1');
});
it('should display timeline info - notes count', () => {
cy.get(TIMELINES_NOTES_COUNT).last().should('have.text', '1');
});
it('should display timeline info - favorite timeline', () => {
cy.get(TIMELINES_FAVORITE).last().should('exist');
});
it('should display timeline content - title', () => {
cy.get(TIMELINE_TITLE).should('have.text', getTimeline().title);
});
it('should display timeline content - description', () => {
cy.get(TIMELINE_DESCRIPTION).should('have.text', getTimeline().description);
});
});

View file

@ -29,7 +29,6 @@ export default defineCypressConfig({
viewportHeight: 1800,
viewportWidth: 1440,
video: false,
videoUploadOnPasses: false,
screenshotOnRunFailure: false,
retries: {
runMode: 1,

View file

@ -1381,10 +1381,10 @@
find-test-names "^1.19.0"
globby "^11.0.4"
"@cypress/request@2.88.12":
version "2.88.12"
resolved "https://registry.yarnpkg.com/@cypress/request/-/request-2.88.12.tgz#ba4911431738494a85e93fb04498cb38bc55d590"
integrity sha512-tOn+0mDZxASFM+cuAP9szGUGPI1HwWVSvdzm7V4cCsPdFTx6qMj29CwaQmRAMIEhORIUBFBsYROYJcveK4uOjA==
"@cypress/request@^3.0.0":
version "3.0.1"
resolved "https://registry.yarnpkg.com/@cypress/request/-/request-3.0.1.tgz#72d7d5425236a2413bd3d8bb66d02d9dc3168960"
integrity sha512-TWivJlJi8ZDx2wGOw1dbLuHJKUYX7bWySw377nlnGOW3hP9/MUKIsEdXT/YngWxVdgNCHRBmFlBipE+5/2ZZlQ==
dependencies:
aws-sign2 "~0.7.0"
aws4 "^1.8.0"
@ -1399,7 +1399,7 @@
json-stringify-safe "~5.0.1"
mime-types "~2.1.19"
performance-now "^2.1.0"
qs "~6.10.3"
qs "6.10.4"
safe-buffer "^5.1.2"
tough-cookie "^4.1.3"
tunnel-agent "^0.6.0"
@ -9459,10 +9459,10 @@
dependencies:
"@types/node" "*"
"@types/node@*", "@types/node@18.17.1", "@types/node@>= 8", "@types/node@>=12.12.47", "@types/node@>=13.7.0", "@types/node@>=8.9.0", "@types/node@^10.1.0", "@types/node@^14.0.10 || ^16.0.0", "@types/node@^14.14.20 || ^16.0.0", "@types/node@^16.18.39", "@types/node@^18.11.18":
version "18.17.1"
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.17.1.tgz#84c32903bf3a09f7878c391d31ff08f6fe7d8335"
integrity sha512-xlR1jahfizdplZYRU59JlUx9uzF1ARa8jbhM11ccpCJya8kvos5jwdm2ZAgxSCwOl0fq21svP18EVwPBXMQudw==
"@types/node@*", "@types/node@18.17.5", "@types/node@>= 8", "@types/node@>=12.12.47", "@types/node@>=13.7.0", "@types/node@>=8.9.0", "@types/node@^10.1.0", "@types/node@^14.0.10 || ^16.0.0", "@types/node@^14.14.20 || ^16.0.0", "@types/node@^18.11.18", "@types/node@^18.17.5":
version "18.17.5"
resolved "https://registry.yarnpkg.com/@types/node/-/node-18.17.5.tgz#c58b12bca8c2a437b38c15270615627e96dd0bc5"
integrity sha512-xNbS75FxH6P4UXTPUJp/zNPq6/xsfdJKussCWNOnz4aULWIRwMgP1LgaB5RiBnMX1DPCYenuqGZfnIAx5mbFLA==
"@types/nodemailer@^6.4.0":
version "6.4.0"
@ -13881,10 +13881,10 @@ cyclist@~0.2.2:
resolved "https://registry.yarnpkg.com/cyclist/-/cyclist-0.2.2.tgz#1b33792e11e914a2fd6d6ed6447464444e5fa640"
integrity sha1-GzN5LhHpFKL9bW7WRHRkRE5fpkA=
cypress-axe@^1.4.0:
version "1.4.0"
resolved "https://registry.yarnpkg.com/cypress-axe/-/cypress-axe-1.4.0.tgz#e67482bfe9e740796bf77c7823f19781a8a2faff"
integrity sha512-Ut7NKfzjyKm0BEbt2WxuKtLkIXmx6FD2j0RwdvO/Ykl7GmB/qRQkwbKLk3VP35+83hiIr8GKD04PDdrTK5BnyA==
cypress-axe@^1.5.0:
version "1.5.0"
resolved "https://registry.yarnpkg.com/cypress-axe/-/cypress-axe-1.5.0.tgz#95082734583da77b51ce9b7784e14a442016c7a1"
integrity sha512-Hy/owCjfj+25KMsecvDgo4fC/781ccL+e8p+UUYoadGVM2ogZF9XIKbiM6KI8Y3cEaSreymdD6ZzccbI2bY0lQ==
cypress-file-upload@^5.0.8:
version "5.0.8"
@ -13906,26 +13906,26 @@ cypress-react-selector@^3.0.0:
dependencies:
resq "1.10.2"
cypress-real-events@^1.8.1:
version "1.8.1"
resolved "https://registry.yarnpkg.com/cypress-real-events/-/cypress-real-events-1.8.1.tgz#d00c7fe93124bbe7c0f27296684838614d24a840"
integrity sha512-8fFnA8EzS3EVbAmpSEUf3A8yZCmfU3IPOSGUDVFCdE1ke1gYL1A+gvXXV6HKUbTPRuvKKt2vpaMbUwYLpDRswQ==
cypress-real-events@^1.10.3:
version "1.10.3"
resolved "https://registry.yarnpkg.com/cypress-real-events/-/cypress-real-events-1.10.3.tgz#e2e949ea509cc4306df6c238de1a9982d67360e5"
integrity sha512-YN3fn+CJIAM638sE6uMvv2/n3PsWowdd0rOiN6ZoyezNAMyENfuQHvccLKZpN+apGfQZYetCml6QXLYgDid2fg==
cypress-recurse@^1.35.1:
version "1.35.1"
resolved "https://registry.yarnpkg.com/cypress-recurse/-/cypress-recurse-1.35.1.tgz#eb737be69231bb38579604f83a17e6e041245b0f"
integrity sha512-NuWKlHJreSbzOmMj1OM/VZgQ+odX22VMeIAKeWQFYflY5+OJCnXMltjOubs725+psB3nQnsgH7122MlGmx60ng==
cypress-recurse@^1.35.2:
version "1.35.2"
resolved "https://registry.yarnpkg.com/cypress-recurse/-/cypress-recurse-1.35.2.tgz#3f49db173beb117196cad82c5484e638e2dc3478"
integrity sha512-G6HfxP90xa7phw8oeOX4uabxcI9gE1ktkKHShcA3nCByrkMLs56+GIJVn0A+ws1tI0PGRKBz6+V9DHS5WnZX4A==
dependencies:
humanize-duration "^3.27.3"
cypress@^12.17.4:
version "12.17.4"
resolved "https://registry.yarnpkg.com/cypress/-/cypress-12.17.4.tgz#b4dadf41673058493fa0d2362faa3da1f6ae2e6c"
integrity sha512-gAN8Pmns9MA5eCDFSDJXWKUpaL3IDd89N9TtIupjYnzLSmlpVr+ZR+vb4U/qaMp+lB6tBvAmt7504c3Z4RU5KQ==
cypress@^13.3.0:
version "13.3.0"
resolved "https://registry.yarnpkg.com/cypress/-/cypress-13.3.0.tgz#d00104661b337d662c5a4280a051ee59f8aa1e31"
integrity sha512-mpI8qcTwLGiA4zEQvTC/U1xGUezVV4V8HQCOYjlEOrVmU1etVvxOjkCXHGwrlYdZU/EPmUiWfsO3yt1o+Q2bgw==
dependencies:
"@cypress/request" "2.88.12"
"@cypress/request" "^3.0.0"
"@cypress/xvfb" "^1.2.4"
"@types/node" "^16.18.39"
"@types/node" "^18.17.5"
"@types/sinonjs__fake-timers" "8.1.1"
"@types/sizzle" "^2.3.2"
arch "^2.2.0"
@ -25106,6 +25106,13 @@ q@^1.5.1:
resolved "https://registry.yarnpkg.com/q/-/q-1.5.1.tgz#7e32f75b41381291d04611f1bf14109ac00651d7"
integrity sha1-fjL3W0E4EpHQRhHxvxQQmsAGUdc=
qs@6.10.4:
version "6.10.4"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.4.tgz#6a3003755add91c0ec9eacdc5f878b034e73f9e7"
integrity sha512-OQiU+C+Ds5qiH91qh/mg0w+8nwQuLjM4F4M/PbmhDOoYehPh+Fb0bDjtR1sOvy7YKxvj28Y/M0PhP5uVX0kB+g==
dependencies:
side-channel "^1.0.4"
qs@6.9.7:
version "6.9.7"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.9.7.tgz#4610846871485e1e048f44ae3b94033f0e675afe"
@ -25125,13 +25132,6 @@ qs@^6.11.0:
dependencies:
side-channel "^1.0.4"
qs@~6.10.3:
version "6.10.5"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.5.tgz#974715920a80ff6a262264acd2c7e6c2a53282b4"
integrity sha512-O5RlPh0VFtR78y79rgcgKK4wbAI0C5zGVLztOIdpWX6ep368q5Hv6XRxDvXuZ9q3C6v+e3n8UfZZJw7IIG27eQ==
dependencies:
side-channel "^1.0.4"
query-string@^6.13.2:
version "6.13.2"
resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.13.2.tgz#3585aa9412c957cbd358fd5eaca7466f05586dda"