Page MenuHomeSoftware Heritage

cypress: Upgrade to version 10
ClosedPublic

Authored by anlambert on Jun 2 2022, 3:29 PM.

Details

Summary

Cypress 10 introduced some breaking changes related to configuration file
and test files naming convention.

Fortunately, its migration tool worked like a charm, all impacted files
were renamed and updated in three clicks.

Diff Detail

Repository
rDWAPPS Web applications
Branch
cypress-10-upgrade
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 29725
Build 46455: Phabricator diff pipeline on jenkinsJenkins console · Jenkins
Build 46454: arc lint + arc unit

Event Timeline

Build has FAILED

Patch application report for D7947 (id=28617)

Rebasing onto 0735488be0...

Current branch diff-target is up to date.
Changes applied before test
commit af022e9657eb12d7887a1cb29032c04d13354500
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1866/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1866/console

Harbormaster returned this revision to the author for changes because remote builds failed.Jun 2 2022, 3:38 PM
Harbormaster failed remote builds in B29702: Diff 28617!

Build has FAILED

Patch application report for D7947 (id=28617)

Rebasing onto 0735488be0...

Current branch diff-target is up to date.
Changes applied before test
commit af022e9657eb12d7887a1cb29032c04d13354500
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1869/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1869/console

Build has FAILED

Patch application report for D7947 (id=28628)

Could not rebase; Attempt merge onto 0735488be0...

Updating 0735488b..71321065
Fast-forward
 cypress.config.js                                  | 40 ++++++++++++++++++++++
 cypress.json                                       | 31 -----------------
 .../add-forge-now-request-create.cy.js}            |  0
 .../add-forge-now-request-dashboard.cy.js}         |  0
 .../add-forge-now-requests-moderation.cy.js}       |  0
 .../{integration/admin.spec.js => e2e/admin.cy.js} |  0
 .../api-tokens.spec.js => e2e/api-tokens.cy.js}    |  0
 .../back-to-top.spec.js => e2e/back-to-top.cy.js}  |  0
 .../code-highlighting.cy.js}                       |  0
 .../content-display.cy.js}                         |  0
 .../content-rendering.cy.js}                       |  0
 .../deposit-admin.cy.js}                           |  0
 .../directory.spec.js => e2e/directory.cy.js}      |  0
 .../errors.spec.js => e2e/errors.cy.js}            |  0
 .../guided-tour.spec.js => e2e/guided-tour.cy.js}  |  0
 .../{integration/home.spec.js => e2e/home.cy.js}   |  0
 .../language-select.cy.js}                         |  0
 .../layout.spec.js => e2e/layout.cy.js}            |  0
 .../mailmap.spec.js => e2e/mailmap.cy.js}          |  0
 .../origin-browse.cy.js}                           |  0
 .../origin-save.spec.js => e2e/origin-save.cy.js}  |  0
 .../origin-search.cy.js}                           |  0
 .../origin-visits.cy.js}                           |  0
 .../persistent-identifiers.cy.js}                  |  0
 .../revision-diff.cy.js}                           |  0
 .../sidebar.spec.js => e2e/sidebar.cy.js}          |  0
 .../{integration/vault.spec.js => e2e/vault.cy.js} |  0
 cypress/support/{index.js => e2e.js}               |  0
 package.json                                       |  2 +-
 swh/web/tests/api/views/test_metadata.py           |  5 +--
 swh/web/tests/api/views/test_origin.py             |  6 ++--
 yarn.lock                                          |  8 ++---
 32 files changed, 52 insertions(+), 40 deletions(-)
 create mode 100644 cypress.config.js
 delete mode 100644 cypress.json
 rename cypress/{integration/add-forge-now-request-create.spec.js => e2e/add-forge-now-request-create.cy.js} (100%)
 rename cypress/{integration/add-forge-now-request-dashboard.spec.js => e2e/add-forge-now-request-dashboard.cy.js} (100%)
 rename cypress/{integration/add-forge-now-requests-moderation.spec.js => e2e/add-forge-now-requests-moderation.cy.js} (100%)
 rename cypress/{integration/admin.spec.js => e2e/admin.cy.js} (100%)
 rename cypress/{integration/api-tokens.spec.js => e2e/api-tokens.cy.js} (100%)
 rename cypress/{integration/back-to-top.spec.js => e2e/back-to-top.cy.js} (100%)
 rename cypress/{integration/code-highlighting.spec.js => e2e/code-highlighting.cy.js} (100%)
 rename cypress/{integration/content-display.spec.js => e2e/content-display.cy.js} (100%)
 rename cypress/{integration/content-rendering.spec.js => e2e/content-rendering.cy.js} (100%)
 rename cypress/{integration/deposit-admin.spec.js => e2e/deposit-admin.cy.js} (100%)
 rename cypress/{integration/directory.spec.js => e2e/directory.cy.js} (100%)
 rename cypress/{integration/errors.spec.js => e2e/errors.cy.js} (100%)
 rename cypress/{integration/guided-tour.spec.js => e2e/guided-tour.cy.js} (100%)
 rename cypress/{integration/home.spec.js => e2e/home.cy.js} (100%)
 rename cypress/{integration/language-select.spec.js => e2e/language-select.cy.js} (100%)
 rename cypress/{integration/layout.spec.js => e2e/layout.cy.js} (100%)
 rename cypress/{integration/mailmap.spec.js => e2e/mailmap.cy.js} (100%)
 rename cypress/{integration/origin-browse.spec.js => e2e/origin-browse.cy.js} (100%)
 rename cypress/{integration/origin-save.spec.js => e2e/origin-save.cy.js} (100%)
 rename cypress/{integration/origin-search.spec.js => e2e/origin-search.cy.js} (100%)
 rename cypress/{integration/origin-visits.spec.js => e2e/origin-visits.cy.js} (100%)
 rename cypress/{integration/persistent-identifiers.spec.js => e2e/persistent-identifiers.cy.js} (100%)
 rename cypress/{integration/revision-diff.spec.js => e2e/revision-diff.cy.js} (100%)
 rename cypress/{integration/sidebar.spec.js => e2e/sidebar.cy.js} (100%)
 rename cypress/{integration/vault.spec.js => e2e/vault.cy.js} (100%)
 rename cypress/support/{index.js => e2e.js} (100%)
Changes applied before test
commit 71321065ff1f3d6de50409f1360ceb062769968f
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

commit ce5824a68aed3b2717542c4e31d99152af7c2605
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 16:47:45 2022 +0200

    tests: Fix flaky ones since hypothesis 6.46.11 release
    
    Some tests became flaky since the latest hypothesis release so
    reduce the number of examples to make them pass again.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1871/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1871/console

Harbormaster returned this revision to the author for changes because remote builds failed.Jun 2 2022, 5:22 PM
Harbormaster failed remote builds in B29711: Diff 28628!
anlambert edited the summary of this revision. (Show Details)

Disable watch file changes by default except when running the cypress UI.

Build was aborted

Patch application report for D7947 (id=28635)

Rebasing onto ce5824a68a...

Current branch diff-target is up to date.
Changes applied before test
commit 87f89d437430a1169a8b01f2201cd0e235c8f29e
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1872/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1872/console

Harbormaster returned this revision to the author for changes because remote builds failed.Jun 2 2022, 6:21 PM
Harbormaster failed remote builds in B29717: Diff 28635!

Build has FAILED

Patch application report for D7947 (id=28635)

Rebasing onto ce5824a68a...

Current branch diff-target is up to date.
Changes applied before test
commit 87f89d437430a1169a8b01f2201cd0e235c8f29e
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1873/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1873/console

Build has FAILED

Patch application report for D7947 (id=28636)

Rebasing onto ce5824a68a...

Current branch diff-target is up to date.
Changes applied before test
commit 31d32d0d0c7a7b51ea76833cea48ae49eef02900
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1874/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1874/console

Harbormaster returned this revision to the author for changes because remote builds failed.Jun 2 2022, 7:37 PM
Harbormaster failed remote builds in B29718: Diff 28636!

Build has FAILED

Patch application report for D7947 (id=28636)

Rebasing onto ce5824a68a...

Current branch diff-target is up to date.
Changes applied before test
commit 31d32d0d0c7a7b51ea76833cea48ae49eef02900
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

Link to build: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1875/
See console output for more information: https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1875/console

I found a cypress regression while testing that upgrade, I have submitted an issue, bug is confirmed and currently investigated.

Let's wait for it to be fixed until landing this.

Build is green

Patch application report for D7947 (id=28642)

Rebasing onto ce5824a68a...

Current branch diff-target is up to date.
Changes applied before test
commit 359f53d348c57fbab1714aa66b298415ce2bdde7
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

See https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1876/ for more details.

ardumont added a subscriber: ardumont.

/me closes his eyes and accepts the diff ¯\_(ツ)_/¯

This revision is now accepted and ready to land.Jun 3 2022, 3:29 PM

/me closes his eyes and accepts the diff ¯\_(ツ)_/¯

The upgrade was basically migrating files in three clicks but at least I found a cypress regression (https://github.com/cypress-io/cypress/issues/22054) that was fixed really quickly.

/me closes his eyes and accepts the diff ¯\_(ツ)_/¯

The upgrade was basically migrating files in three clicks but at least I found a cypress regression (https://github.com/cypress-io/cypress/issues/22054) that was fixed really quickly.

yes, I read the description and changes (config.cypress.json) and the new release/upgrade to 10.0.2 (I did not follow through the github issue though [1]).
I don't see much to say but ok.

[1] well now i did ;)

Build is green

Patch application report for D7947 (id=28678)

Rebasing onto 3a4e607645...

Current branch diff-target is up to date.
Changes applied before test
commit 631925c646cdd09a8714af10415ed57ae5a2cdaa
Author: Antoine Lambert <anlambert@softwareheritage.org>
Date:   Thu Jun 2 15:27:07 2022 +0200

    cypress: Upgrade to version 10
    
    Cypress 10 introduced some breaking changes related to configuration file
    and test files naming convention.
    
    Fortunately, its migration tool worked like a charm, all impacted files
    were renamed and updated in three clicks.

See https://jenkins.softwareheritage.org/job/DWAPPS/job/tests-on-diff/1882/ for more details.

This revision was automatically updated to reflect the committed changes.