Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Cypress test for incoming user verification #11688

Merged
merged 3 commits into from
Oct 2, 2023

Conversation

richvdh
Copy link
Member

@richvdh richvdh commented Sep 29, 2023

... because it turned out we didn't have one, and it was broken (element-hq/element-web#26245)


This change is marked as an internal change (Task), so will not be included in the changelog.

@richvdh richvdh requested a review from a team as a code owner September 29, 2023 16:15
@richvdh richvdh added the T-Task Refactoring, enabling or disabling functionality, other engineering tasks label Sep 29, 2023
@richvdh richvdh enabled auto-merge October 2, 2023 10:39
@richvdh
Copy link
Member Author

richvdh commented Oct 2, 2023

Looks like this might have caused some brokenness:


  1) Cryptography
       should allow verification when there is no existing DM:
     CypressError: `cy.then()` failed because you are mixing up async and sync code.

In your callback function you invoked 1 or more cy commands but then returned a synchronous value.

Cypress commands are asynchronous and it doesn't make sense to queue cy commands and yet return a synchronous value.

You likely forgot to properly chain the cy commands using another `cy.then()`.

The value you synchronously returned was: `!dvafiRlnhyVMVzYeOY:localhost`
      at getRet (http://localhost:8080/__cypress/runner/cypress_runner.js:145225:78)
      at tryCatcher (http://localhost:8080/__cypress/runner/cypress_runner.js:18744:23)
      at Promise.attempt.Promise.try (http://localhost:8080/__cypress/runner/cypress_runner.js:16018:29)
      at Context.thenFn (http://localhost:8080/__cypress/runner/cypress_runner.js:145234:63)
      at Context.then (http://localhost:8080/__cypress/runner/cypress_runner.js:145483:21)
      at wrapped (http://localhost:8080/__cypress/runner/cypress_runner.js:160816:19)
  From Your Spec Code:
      at createSharedRoomWithUser (webpack:///./cypress/e2e/crypto/utils.ts:207:83)
      at Context.eval (webpack:///./cypress/e2e/crypto/crypto.spec.ts:244:0)

  2) Cryptography
       event shields
         "before each" hook for "should show the correct shield on e2e events":
     CypressError: `cy.then()` failed because you are mixing up async and sync code.

In your callback function you invoked 1 or more cy commands but then returned a synchronous value.

Cypress commands are asynchronous and it doesn't make sense to queue cy commands and yet return a synchronous value.

You likely forgot to properly chain the cy commands using another `cy.then()`.

The value you synchronously returned was: `!MWXWaYbpZQERcdvdRh:localhost`

Because this error occurred during a `before each` hook we are skipping the remaining tests in the current suite: `event shields`
      at getRet (http://localhost:8080/__cypress/runner/cypress_runner.js:145225:78)
      at tryCatcher (http://localhost:8080/__cypress/runner/cypress_runner.js:18744:23)
      at Promise.attempt.Promise.try (http://localhost:8080/__cypress/runner/cypress_runner.js:16018:29)
      at Context.thenFn (http://localhost:8080/__cypress/runner/cypress_runner.js:145234:63)
      at Context.then (http://localhost:8080/__cypress/runner/cypress_runner.js:145483:21)
      at wrapped (http://localhost:8080/__cypress/runner/cypress_runner.js:160816:19)
  From Your Spec Code:
      at createSharedRoomWithUser (webpack:///./cypress/e2e/crypto/utils.ts:207:83)
      at Context.eval (webpack:///./cypress/e2e/crypto/crypto.spec.ts:253:0)

@richvdh richvdh self-assigned this Oct 2, 2023
@richvdh richvdh added this pull request to the merge queue Oct 2, 2023
Merged via the queue into develop with commit 6e55926 Oct 2, 2023
@richvdh richvdh deleted the rav/user_verification_test branch October 2, 2023 19:41
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
T-Task Refactoring, enabling or disabling functionality, other engineering tasks
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants