@@ -6,13 +6,12 @@ import {
6
6
cloudDatabaseConfig
7
7
} from '../../../helpers/conf' ;
8
8
import { rte } from '../../../helpers/constants' ;
9
- import { MyRedisDatabasePage } from '../../../pageObjects' ;
9
+ import { AutoDiscoverREDatabases , MyRedisDatabasePage } from '../../../pageObjects' ;
10
10
11
11
const myRedisDatabasePage = new MyRedisDatabasePage ( ) ;
12
+ const autoDiscoverREDatabases = new AutoDiscoverREDatabases ( ) ;
12
13
const databaseHelper = new DatabaseHelper ( ) ;
13
14
14
- let databaseName : string ;
15
-
16
15
fixture `Add database`
17
16
. meta ( { type : 'smoke' } )
18
17
. page ( commonUrl )
44
43
. meta ( { rte : rte . reCloud } )
45
44
. after ( async ( ) => {
46
45
// await deleteDatabase(databaseName);
47
- } ) ( 'Verify that user can connect to the RE Cloud database via auto-discover flow' , async t => {
46
+ } ) ( 'Verify that user can add a subscription via auto-discover flow' , async t => {
48
47
// Verify that user can see the Cloud auto-discovery option selected by default when switching to the auto-discovery of databases
49
- databaseName = await databaseHelper . autodiscoverRECloudDatabase ( cloudDatabaseConfig . accessKey , cloudDatabaseConfig . secretKey ) ;
50
- // uncomment when fixed db will be added to cloud subscription
51
- // await myRedisDatabasePage.clickOnDBByName(databaseName);
52
- // // Verify that user can add database from fixed subscription
53
- // await t.expect(Common.getPageUrl()).contains('browser', 'The added RE Cloud database not opened');
48
+ await t . click (
49
+ myRedisDatabasePage . AddRedisDatabase . addRedisDatabaseButton ) ;
50
+ await t . expect ( autoDiscoverREDatabases . title . withExactText ( 'Redis Enterprise Cloud Subscriptions' ) . exists )
51
+ . ok ( 'Subscriptions list not displayed' , { timeout : 120000 } ) ;
52
+ // Select subscriptions
53
+ await t . click ( myRedisDatabasePage . AddRedisDatabase . selectAllCheckbox ) ;
54
+ await t . click ( myRedisDatabasePage . AddRedisDatabase . showDatabasesButton ) ;
55
+ await t . expect ( autoDiscoverREDatabases . title . withExactText ( 'Redis Enterprise Cloud Databases' ) . exists )
56
+ . ok ( 'database page is not displayed' , { timeout : 120000 } ) ;
54
57
} ) ;
0 commit comments