Skip to content

Commit c8353b5

Browse files
committed
Fixed tests for the prupose of running separatelly.
1 parent a200b33 commit c8353b5

1 file changed

Lines changed: 8 additions & 9 deletions

File tree

  • x-pack/test/functional/apps/lens/group3/open_in_lens/tsvb

x-pack/test/functional/apps/lens/group3/open_in_lens/tsvb/timeseries.ts

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,14 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
2727
await visualize.initTests();
2828
});
2929

30-
it('should show the "Edit Visualization in Lens" menu item for a count aggregation', async () => {
30+
beforeEach(async () => {
3131
await visualize.navigateToNewVisualization();
3232
await visualize.clickVisualBuilder();
3333
await visualBuilder.checkVisualBuilderIsPresent();
3434
await visualBuilder.resetPage();
35+
});
36+
37+
it('should show the "Edit Visualization in Lens" menu item for a count aggregation', async () => {
3538
const isMenuItemVisible = await find.existsByCssSelector(
3639
'[data-test-subj="visualizeEditInLensButton"]'
3740
);
@@ -51,6 +54,10 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
5154
});
5255

5356
it('navigates back to TSVB when the Back button is clicked', async () => {
57+
const button = await testSubjects.find('visualizeEditInLensButton');
58+
await button.click();
59+
await lens.waitForVisualization('xyVisChart');
60+
5461
const goBackBtn = await testSubjects.find('lnsApp_goBackToAppButton');
5562
goBackBtn.click();
5663
await visualBuilder.checkVisualBuilderIsPresent();
@@ -71,9 +78,6 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
7178
});
7279

7380
it('should preserve query in lens', async () => {
74-
const goBackBtn = await testSubjects.find('lnsApp_goBackToAppButton');
75-
goBackBtn.click();
76-
await visualBuilder.checkVisualBuilderIsPresent();
7781
await queryBar.setQuery('machine.os : ios');
7882
await queryBar.submitQuery();
7983
await header.waitUntilLoadingHasFinished();
@@ -85,11 +89,6 @@ export default function ({ getPageObjects, getService }: FtrProviderContext) {
8589
});
8690

8791
it('should draw a reference line', async () => {
88-
await visualize.navigateToNewVisualization();
89-
await visualize.clickVisualBuilder();
90-
await visualBuilder.checkVisualBuilderIsPresent();
91-
await visualBuilder.resetPage();
92-
9392
await visualBuilder.createNewAggSeries();
9493
await visualBuilder.selectAggType('Static Value');
9594
await visualBuilder.setStaticValue(10);

0 commit comments

Comments
 (0)