|
1 | 1 | import { DatabaseHelper } from '../../../../helpers/database';
|
2 |
| -import { BrowserPage } from '../../../../pageObjects'; |
| 2 | +import { BrowserPage, WorkbenchPage } from '../../../../pageObjects'; |
3 | 3 | import {
|
4 | 4 | commonUrl,
|
5 | 5 | ossStandaloneBigConfig,
|
6 | 6 | ossStandaloneConfig,
|
7 | 7 | ossStandaloneConfigEmpty,
|
8 | 8 | ossStandaloneRedisearch, ossStandaloneRedisGears
|
9 | 9 | } from '../../../../helpers/conf';
|
10 |
| -import { KeyTypesTexts, rte } from '../../../../helpers/constants'; |
| 10 | +import { ExploreTabs, KeyTypesTexts, rte } from '../../../../helpers/constants'; |
11 | 11 | import { DatabaseAPIRequests } from '../../../../helpers/api/api-database';
|
12 | 12 | import { APIKeyRequests } from '../../../../helpers/api/api-keys';
|
13 | 13 | import { Common } from '../../../../helpers/common';
|
14 | 14 | import { verifyKeysDisplayingInTheList } from '../../../../helpers/keys';
|
15 | 15 |
|
16 | 16 | const browserPage = new BrowserPage();
|
| 17 | +const workbenchPage = new WorkbenchPage(); |
17 | 18 | const databaseHelper = new DatabaseHelper();
|
18 | 19 | const databaseAPIRequests = new DatabaseAPIRequests();
|
19 | 20 | const apiKeyRequests = new APIKeyRequests();
|
|
41 | 42 | const message = 'Let\'sstartworkingLoadsampledata+Addkeymanually';
|
42 | 43 | const actualMessage = await browserPage.keyListMessage.innerText;
|
43 | 44 | const cleanMessage = actualMessage.replace(/[\s\n]+/g, '');
|
| 45 | + const capabilities = [{ |
| 46 | + name: 'Search and Query', |
| 47 | + tutorial: 'How To Query Your Data' |
| 48 | + }, |
| 49 | + { |
| 50 | + name: 'JSON', |
| 51 | + tutorial: 'JSON' |
| 52 | + }, |
| 53 | + { |
| 54 | + name: 'Triggers and functions', |
| 55 | + tutorial: 'Triggers And Functions Explained' |
| 56 | + }, |
| 57 | + { |
| 58 | + name: 'Time Series', |
| 59 | + tutorial: 'Time Series' |
| 60 | + }, |
| 61 | + { |
| 62 | + name: 'Probabilistic', |
| 63 | + tutorial: 'Probabilistic' |
| 64 | + }]; |
| 65 | + |
| 66 | + await t.expect(browserPage.guideLinksBtn.count).gte(5); |
| 67 | + for (const capability of capabilities) { |
| 68 | + await browserPage.clickGuideLinksByName(capability.name); |
| 69 | + await t.expect(browserPage.InsightsPanel.sidePanel.exists).ok('Insights panel not opened'); |
| 70 | + const tutorials = await workbenchPage.InsightsPanel.setActiveTab(ExploreTabs.Explore); |
| 71 | + await t.expect(tutorials.closeEnablementPage.textContent) |
| 72 | + .contains(capability.tutorial, `${capability.tutorial} tutorial not opened from No Keys page`); |
| 73 | + await t.click(browserPage.InsightsPanel.closeButton); |
| 74 | + } |
44 | 75 |
|
45 | 76 | // Verify the message
|
46 | 77 | await t.click(browserPage.treeViewButton);
|
|
0 commit comments