Skip to content

Commit 3284c56

Browse files
Merge pull request #4170 from RedisInsight/e2e/feature/update-ssh-test
update ssh test
2 parents 3533807 + b491b24 commit 3284c56

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

tests/e2e/tests/electron/critical-path/database/add-ssh-db.e2e.ts

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { rte } from '../../../../helpers/constants';
2-
import { BrowserPage, MyRedisDatabasePage } from '../../../../pageObjects';
2+
import { BrowserPage, ClusterDetailsPage, MyRedisDatabasePage } from '../../../../pageObjects';
33
import { commonUrl, ossClusterForSSHConfig, ossStandaloneForSSHConfig } from '../../../../helpers/conf';
44
import { DatabaseHelper } from '../../../../helpers/database';
55
import { DatabaseAPIRequests } from '../../../../helpers/api/api-database';
@@ -9,6 +9,7 @@ import { BrowserActions } from '../../../../common-actions/browser-actions';
99

1010
const myRedisDatabasePage = new MyRedisDatabasePage();
1111
const browserPage = new BrowserPage();
12+
const clusterPage = new ClusterDetailsPage();
1213
const databaseHelper = new DatabaseHelper();
1314
const databaseAPIRequests = new DatabaseAPIRequests();
1415
const browserActions = new BrowserActions();
@@ -122,13 +123,21 @@ test('Adding database with SSH', async t => {
122123
await myRedisDatabasePage.clickOnDBByName(sshDbPasscode.databaseName);
123124
await Common.checkURLContainsText('browser');
124125
});
125-
test('Adding OSS Cluster database with SSH', async t => {
126+
test('Verify that OSS Cluster database with SSH can be added and work correctly', async t => {
126127
const sshWithPass = {
127128
...sshParams,
128129
sshPassword: 'pass'
129130
};
130131
// Verify that user can add SSH tunnel with Password for OSS Cluster database
131132
await myRedisDatabasePage.AddRedisDatabase.addStandaloneSSHDatabase(sshDbClusterPass, sshWithPass);
132133
await myRedisDatabasePage.clickOnDBByName(sshDbPass.databaseName);
133-
await Common.checkURLContainsText('browser');
134+
135+
//verify that db is added and profiler works
136+
await t.click(browserPage.Profiler.expandMonitor);
137+
await t.click(browserPage.Profiler.startMonitorButton);
138+
await t.expect(browserPage.Profiler.monitorIsStartedText.innerText).eql('Profiler is started.');
139+
140+
await t.click(browserPage.NavigationPanel.analysisPageButton);
141+
await t.click(clusterPage.overviewTab);
142+
await t.expect(await clusterPage.getPrimaryNodesCount()).eql(Number('3'), 'Primary nodes in table are not corrected');
134143
});

0 commit comments

Comments
 (0)