mirror of
https://github.com/grafana/grafana.git
synced 2024-11-24 09:50:29 -06:00
94294a72c8
Update e2e test
40 lines
1.1 KiB
TypeScript
40 lines
1.1 KiB
TypeScript
import { e2e } from '@grafana/e2e';
|
|
|
|
describe('Trace view', () => {
|
|
it('Can lazy load big traces', () => {
|
|
e2e.flows.login('admin', 'admin');
|
|
e2e()
|
|
.intercept('GET', '**/api/traces/trace', {
|
|
fixture: 'long-trace-response.json',
|
|
})
|
|
.as('longTrace');
|
|
|
|
e2e.pages.Explore.visit();
|
|
|
|
e2e.components.DataSourcePicker.container().should('be.visible').type('gdev-jaeger{enter}');
|
|
|
|
e2e().wait(500);
|
|
|
|
e2e.components.QueryField.container().should('be.visible').type('trace', { delay: 100 });
|
|
|
|
e2e().wait(500);
|
|
|
|
e2e.components.RefreshPicker.runButtonV2().should('be.visible').click();
|
|
|
|
e2e().wait('@longTrace');
|
|
|
|
e2e.components.TraceViewer.spanBar().should('be.visible');
|
|
|
|
e2e.components.TraceViewer.spanBar()
|
|
.its('length')
|
|
.then((oldLength) => {
|
|
e2e.pages.Explore.General.scrollView().children('.scrollbar-view').scrollTo('center');
|
|
|
|
// After scrolling we should load more spans
|
|
e2e.components.TraceViewer.spanBar().should(($span) => {
|
|
expect($span.length).to.be.gt(oldLength);
|
|
});
|
|
});
|
|
});
|
|
});
|