Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(cypress): Add E2E tests for promoting highlight annotations #623

Merged
merged 2 commits into from
Oct 9, 2020

Conversation

mxiao6
Copy link
Contributor

@mxiao6 mxiao6 commented Oct 9, 2020

No description provided.

@mxiao6 mxiao6 requested a review from a team as a code owner October 9, 2020 18:39
jstoffan
jstoffan previously approved these changes Oct 9, 2020
cy.getByTestId('ba-Layer--highlight');

// Assert that only one highlight annotation created in the above test is present
cy.get('.ba-HighlightTarget').should('have.length', 1);
Copy link
Contributor

Choose a reason for hiding this comment

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

Can cypress tests be run individually? Seems like we should try to avoid relying on side effects of other tests if possible

Copy link
Collaborator

Choose a reason for hiding this comment

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

We would need to manually delete any existing annotations in a teardown step after each test and/or suite.

Copy link
Contributor

Choose a reason for hiding this comment

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

That or we could go back to that logic @mxiao6 had to count the annotations before and after so it's more of a relative check?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

How about combining them into one test?

@mxiao6 mxiao6 force-pushed the test-highlight-promotion branch from ce1b300 to 8f779f2 Compare October 9, 2020 19:45
@mergify mergify bot merged commit 0d00b10 into box:master Oct 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants