test: Adding scrolling test

pull/18359/head
Zoe Steinkamp 2020-05-20 16:37:59 -06:00
parent a6ead1246e
commit ff37c7a90d
2 changed files with 22 additions and 0 deletions

View File

@ -749,6 +749,27 @@ describe('DataExplorer', () => {
})
})
})
it.only('can view table data with raw data & scroll', () => {
// build the query to return data from beforeEach
cy.getByTestID(`selector-list m`).click()
cy.getByTestID('selector-list v').click()
cy.getByTestID(`selector-list tv1`).click()
cy.getByTestID('selector-list sort').click()
cy.getByTestID('time-machine-submit-button').click()
cy.getByTestID('view-type--dropdown').click()
cy.getByTestID(`view-type--table`).click()
// check to see that the FE rows are NOT sorted with flux sort
cy.get('.table-graph-cell__sort-asc').should('not.exist')
cy.get('.table-graph-cell__sort-desc').should('not.exist')
// view raw data table
cy.getByTestID('raw-data--toggle').click()
cy.getByTestID('raw-data-table').should('exist')
//scroll to the bottom and make sure things load
cy.getByTestID('rawdata-table--scrollbar').scrollTo('bottom')
})
})
})

View File

@ -42,6 +42,7 @@ class RawFluxDataTable extends PureComponent<Props, State> {
autoHide={false}
scrollTop={scrollTop}
scrollLeft={scrollLeft}
testID="rawdata-table--scrollbar"
onScroll={this.onScrollbarsScroll}
>
<RawFluxDataGrid