Skip to content

Conversation

@mayagbarnes
Copy link
Collaborator

📚 Context

Upgrading our Cypress version from v6.9.1 to v9.7.0. This significantly improves our Cypress test flakiness: 3 of the last 10 Cypress test runs on develop failed as a result of hitting the Cypress verification timing out.

  • What kind of change does this PR introduce?
    • Other, please describe: Infrastructure

🧠 Description of Changes

  • Upgrade Cypress versions
  • Add CYPRESS_VERIFY_TIMEOUT env variable to reduce occurrences of failed verification
  • Update all snapshots

🧪 Testing Done

  • Added/Updated e2e tests

@mayagbarnes mayagbarnes added the security-assessment-completed Security assessment has been completed for PR label Mar 15, 2023
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cypress has removed the moment.js lib and recommends using dayjs instead

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Resulting snapshot change as part of adding .wait

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adding the .wait is necessary to make sure the background of the map completely loads.
Without using wait to ensure background load, this test is flaky - sometimes the background will load before the snap is taken for comparison and sometimes it won't - causing failure.

@mayagbarnes mayagbarnes marked this pull request as ready for review March 16, 2023 05:07
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you verify this manually? The iframe e2e test focuses on expanding to avoid scrolling necessarily. The screenshots being larger give me pause (but unlikely is a problem)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the most interesting one to me on what's going on...I imagine it's viewport stuff.

@mayagbarnes mayagbarnes merged commit 2e023a8 into develop Mar 16, 2023
@mayagbarnes mayagbarnes deleted the feature/cypress-upgrade branch March 16, 2023 22:36
tconkling added a commit to tconkling/streamlit that referenced this pull request Mar 17, 2023
* develop: (48 commits)
  ForwardMessageCache: interface-ize endpoint (streamlit#6326)
  Add an event handler for popstate event to reflect user's back button being clicked (streamlit#6271)
  Cypress Upgrade to 9.7.0 (streamlit#6322)
  Remove default values from internal class reprs
  FileUploadClient: interface-ize endpoint (streamlit#6323)
  Fix issue streamlit#6310 (streamlit#6321)
  Make using @ts-ignore illegal (streamlit#6314)
  Add nightly-preview deploy to nightly build (streamlit#6306)
  Minor documentation fixes for cache storage (streamlit#6222)
  Add react-dropzone prop to address disabled file type behavior (streamlit#6315)
  Add timeout to label-markdown spec (streamlit#6312)
  ascii diagrams for CacheStorage* protocols, and for LocalDiskCacheStorage* concrete implementation (streamlit#6220)
  Bump @sideway/formula from 3.0.0 to 3.0.1 in /frontend (streamlit#6309)
  Bump webpack from 5.75.0 to 5.76.0 in /frontend (streamlit#6313)
  Replace @ts-ignore with @ts-expect-error and remove unused directives (streamlit#6308)
  Up version to 1.20.0 (streamlit#6284)
  Pull ComponentRegistry's URL generation into an interface (streamlit#6307)
  Add st.divider (streamlit#6178)
  fix: upgrade multiple dependencies with Snyk (streamlit#6262)
  Activate the no-unused-vars rule in eslint. (streamlit#6300)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

security-assessment-completed Security assessment has been completed for PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants