-
Notifications
You must be signed in to change notification settings - Fork 14.5k
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
Cypress tests for controls and explore links #6069
Cypress tests for controls and explore links #6069
Conversation
@@ -63,6 +65,7 @@ export default class ControlHeader extends React.Component { | |||
return ( | |||
<div | |||
className="ControlHeader" | |||
data-test={`${this.props.name}-header`} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added this for annotations because I couldn't find another way to distinguish the controls in annotations from one another. The rest of controls use the Controls
component (which has data-test already set) but annotations just use the controls themselves. If anyone is familiar with annotations and has another idea for identifying the controls let me know.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few nits but overall LGTM
@@ -188,6 +188,7 @@ class SaveModal extends React.Component { | |||
disabled={canNotSaveToDash} | |||
checked={this.state.addToDash === 'existing'} | |||
onChange={this.changeDash.bind(this, 'existing')} | |||
data-test="add_to_existing_dashboard" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be dash -
instead of underscore _
?
@@ -206,6 +207,7 @@ class SaveModal extends React.Component { | |||
checked={this.state.addToDash === 'new'} | |||
onChange={this.changeDash.bind(this, 'new')} | |||
disabled={canNotSaveToDash} | |||
data-test="add_to_new_dashboard" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this be dash -
instead of underscore _
?
.first() | ||
.invoke('text') | ||
.then((text) => { | ||
cy.visit(text); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indent
cy.get('.select.save-modal-selector').click().within(() => { | ||
cy.get('input').type(dashboardTitle, { force: true }); | ||
cy.get('.select-option.is-focused') | ||
.trigger('mousedown'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indent
5c7b539
to
59400c5
Compare
Codecov Report
@@ Coverage Diff @@
## master #6069 +/- ##
=======================================
Coverage 77.55% 77.55%
=======================================
Files 47 47
Lines 9485 9485
=======================================
Hits 7356 7356
Misses 2129 2129 Continue to review full report at Codecov.
|
* Adding tests for controls * Adding tests for explore links
Adding some tests to set and alter some of the more complex controls, as well as, adding tests for links on explore.
@kristw @graceguo-supercat