@@ -296,19 +296,16 @@ export class BrowserPage {
296
296
* @param TTL The Time to live value of the key (optional parameter)
297
297
*/
298
298
async addJsonKey ( keyName : string , value : string , TTL ?: string ) : Promise < void > {
299
- await t
300
- . click ( this . plusAddKeyButton )
301
- . click ( this . keyTypeDropDown )
302
- . click ( this . jsonOption )
303
- . click ( this . addKeyNameInput ) ;
304
- await t
305
- . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } )
306
- . click ( this . jsonKeyValueInput )
307
- . typeText ( this . jsonKeyValueInput , value , { replace : true , paste : true } ) ;
299
+ await t . click ( this . plusAddKeyButton ) ;
300
+ await t . click ( this . keyTypeDropDown ) ;
301
+ await t . click ( this . jsonOption ) ;
302
+ await t . click ( this . addKeyNameInput ) ;
303
+ await t . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } ) ;
304
+ await t . click ( this . jsonKeyValueInput ) ;
305
+ await t . typeText ( this . jsonKeyValueInput , value , { replace : true , paste : true } ) ;
308
306
if ( TTL !== undefined ) {
309
- await t
310
- . click ( this . keyTTLInput )
311
- . typeText ( this . keyTTLInput , TTL ) ;
307
+ await t . click ( this . keyTTLInput ) ;
308
+ await t . typeText ( this . keyTTLInput , TTL ) ;
312
309
}
313
310
await t . click ( this . addKeyButton ) ;
314
311
}
@@ -321,16 +318,15 @@ export class BrowserPage {
321
318
*/
322
319
async addSetKey ( keyName : string , TTL = ' ' , members = ' ' ) : Promise < void > {
323
320
await common . waitForElementNotVisible ( this . progressLine ) ;
324
- await t
325
- . click ( this . plusAddKeyButton )
326
- . click ( this . keyTypeDropDown )
327
- . click ( this . setOption )
328
- . click ( this . addKeyNameInput )
329
- . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } )
330
- . click ( this . keyTTLInput )
331
- . typeText ( this . keyTTLInput , TTL )
332
- . typeText ( this . setMemberInput , members , { replace : true , paste : true } )
333
- . click ( this . addKeyButton ) ;
321
+ await t . click ( this . plusAddKeyButton ) ;
322
+ await t . click ( this . keyTypeDropDown ) ;
323
+ await t . click ( this . setOption ) ;
324
+ await t . click ( this . addKeyNameInput ) ;
325
+ await t . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } ) ;
326
+ await t . click ( this . keyTTLInput ) ;
327
+ await t . typeText ( this . keyTTLInput , TTL ) ;
328
+ await t . typeText ( this . setMemberInput , members , { replace : true , paste : true } ) ;
329
+ await t . click ( this . addKeyButton ) ;
334
330
}
335
331
336
332
/**
@@ -342,17 +338,16 @@ export class BrowserPage {
342
338
*/
343
339
async addZSetKey ( keyName : string , scores = ' ' , TTL = ' ' , members = ' ' ) : Promise < void > {
344
340
await common . waitForElementNotVisible ( this . progressLine ) ;
345
- await t
346
- . click ( this . plusAddKeyButton )
347
- . click ( this . keyTypeDropDown )
348
- . click ( this . zsetOption )
349
- . click ( this . addKeyNameInput )
350
- . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } )
351
- . click ( this . keyTTLInput )
352
- . typeText ( this . keyTTLInput , TTL , { replace : true , paste : true } )
353
- . typeText ( this . setMemberInput , members , { replace : true , paste : true } )
354
- . typeText ( this . zsetMemberScoreInput , scores , { replace : true , paste : true } )
355
- . click ( this . addKeyButton ) ;
341
+ await t . click ( this . plusAddKeyButton ) ;
342
+ await t . click ( this . keyTypeDropDown ) ;
343
+ await t . click ( this . zsetOption ) ;
344
+ await t . click ( this . addKeyNameInput ) ;
345
+ await t . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } ) ;
346
+ await t . click ( this . keyTTLInput ) ;
347
+ await t . typeText ( this . keyTTLInput , TTL , { replace : true , paste : true } ) ;
348
+ await t . typeText ( this . setMemberInput , members , { replace : true , paste : true } ) ;
349
+ await t . typeText ( this . zsetMemberScoreInput , scores , { replace : true , paste : true } ) ;
350
+ await t . click ( this . addKeyButton ) ;
356
351
}
357
352
358
353
/**
@@ -363,17 +358,16 @@ export class BrowserPage {
363
358
*/
364
359
async addListKey ( keyName : string , TTL = ' ' , element = ' ' ) : Promise < void > {
365
360
await common . waitForElementNotVisible ( this . progressLine ) ;
366
- await t
367
- . click ( this . plusAddKeyButton )
368
- . click ( this . keyTypeDropDown )
369
- . click ( this . listOption )
370
- . click ( this . addKeyNameInput )
371
- . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } )
372
- . click ( this . keyTTLInput )
373
- . typeText ( this . keyTTLInput , TTL )
374
- . click ( this . listKeyElementInput )
375
- . typeText ( this . listKeyElementInput , element , { replace : true , paste : true } )
376
- . click ( this . addKeyButton ) ;
361
+ await t . click ( this . plusAddKeyButton ) ;
362
+ await t . click ( this . keyTypeDropDown ) ;
363
+ await t . click ( this . listOption ) ;
364
+ await t . click ( this . addKeyNameInput ) ;
365
+ await t . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } ) ;
366
+ await t . click ( this . keyTTLInput ) ;
367
+ await t . typeText ( this . keyTTLInput , TTL ) ;
368
+ await t . click ( this . listKeyElementInput ) ;
369
+ await t . typeText ( this . listKeyElementInput , element , { replace : true , paste : true } ) ;
370
+ await t . click ( this . addKeyButton ) ;
377
371
}
378
372
379
373
/**
@@ -385,17 +379,16 @@ export class BrowserPage {
385
379
*/
386
380
async addHashKey ( keyName : string , TTL = ' ' , field = ' ' , value = ' ' ) : Promise < void > {
387
381
await common . waitForElementNotVisible ( this . progressLine ) ;
388
- await t
389
- . click ( this . plusAddKeyButton )
390
- . click ( this . keyTypeDropDown )
391
- . click ( this . hashOption )
392
- . click ( this . addKeyNameInput )
393
- . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } )
394
- . click ( this . keyTTLInput )
395
- . typeText ( this . keyTTLInput , TTL , { replace : true , paste : true } )
396
- . typeText ( this . hashFieldNameInput , field , { replace : true , paste : true } )
397
- . typeText ( this . hashFieldValueInput , value , { replace : true , paste : true } )
398
- . click ( this . addKeyButton ) ;
382
+ await t . click ( this . plusAddKeyButton ) ;
383
+ await t . click ( this . keyTypeDropDown ) ;
384
+ await t . click ( this . hashOption ) ;
385
+ await t . click ( this . addKeyNameInput ) ;
386
+ await t . typeText ( this . addKeyNameInput , keyName , { replace : true , paste : true } ) ;
387
+ await t . click ( this . keyTTLInput ) ;
388
+ await t . typeText ( this . keyTTLInput , TTL , { replace : true , paste : true } ) ;
389
+ await t . typeText ( this . hashFieldNameInput , field , { replace : true , paste : true } ) ;
390
+ await t . typeText ( this . hashFieldValueInput , value , { replace : true , paste : true } ) ;
391
+ await t . click ( this . addKeyButton ) ;
399
392
}
400
393
401
394
/**
@@ -409,13 +402,12 @@ export class BrowserPage {
409
402
await this . commonAddNewKey ( keyName , TTL ) ;
410
403
await t . click ( this . streamOption ) ;
411
404
// Verify that user can see Entity ID filled by * by default on add Stream key form
412
- await t
413
- . expect ( this . streamEntryId . withAttribute ( 'value' , '*' ) . exists ) . ok ( 'Preselected Stream Entity ID field not displayed' )
414
- . typeText ( this . streamField , field , { replace : true , paste : true } )
415
- . typeText ( this . streamValue , value , { replace : true , paste : true } )
416
- . expect ( this . addKeyButton . withAttribute ( 'disabled' ) . exists ) . notOk ( 'Add Key button not clickable' )
417
- . click ( this . addKeyButton )
418
- . click ( this . toastCloseButton ) ;
405
+ await t . expect ( this . streamEntryId . withAttribute ( 'value' , '*' ) . exists ) . ok ( 'Preselected Stream Entity ID field not displayed' ) ;
406
+ await t . typeText ( this . streamField , field , { replace : true , paste : true } ) ;
407
+ await t . typeText ( this . streamValue , value , { replace : true , paste : true } ) ;
408
+ await t . expect ( this . addKeyButton . withAttribute ( 'disabled' ) . exists ) . notOk ( 'Add Key button not clickable' ) ;
409
+ await t . click ( this . addKeyButton ) ;
410
+ await t . click ( this . toastCloseButton ) ;
419
411
}
420
412
421
413
/**
@@ -752,44 +744,41 @@ export class BrowserPage {
752
744
753
745
//Remove List element from head for Redis databases less then v. 6.2.
754
746
async removeListElementFromHeadOld ( ) : Promise < void > {
755
- await t
756
- . click ( this . removeElementFromListIconButton )
757
- . expect ( this . countInput . withAttribute ( 'disabled' ) . exists ) . ok ( 'Input field not disabled' )
747
+ await t . click ( this . removeElementFromListIconButton ) ;
748
+ await t . expect ( this . countInput . withAttribute ( 'disabled' ) . exists ) . ok ( 'Input field not disabled' ) ;
758
749
//Select Remove from head selection
759
- . click ( this . removeElementFromListSelect )
760
- . click ( this . removeFromHeadSelection )
750
+ await t . click ( this . removeElementFromListSelect ) ;
751
+ await t . click ( this . removeFromHeadSelection ) ;
761
752
//Confirm removing
762
- . click ( this . removeElementFromListButton )
763
- . click ( this . confirmRemoveListElementButton ) ;
753
+ await t . click ( this . removeElementFromListButton ) ;
754
+ await t . click ( this . confirmRemoveListElementButton ) ;
764
755
}
765
756
766
757
/**
767
758
* Remove List element from tail
768
759
* @param count The count if elements for removing
769
760
*/
770
761
async removeListElementFromTail ( count : string ) : Promise < void > {
771
- await t
772
- . click ( this . removeElementFromListIconButton )
773
- . typeText ( this . countInput , count , { replace : true , paste : true } )
774
- . click ( this . removeElementFromListButton )
775
- . click ( this . confirmRemoveListElementButton ) ;
762
+ await t . click ( this . removeElementFromListIconButton ) ;
763
+ await t . typeText ( this . countInput , count , { replace : true , paste : true } ) ;
764
+ await t . click ( this . removeElementFromListButton ) ;
765
+ await t . click ( this . confirmRemoveListElementButton ) ;
776
766
}
777
767
778
768
/**
779
769
* Remove List element from head
780
770
* @param count The count if elements for removing
781
771
*/
782
772
async removeListElementFromHead ( count : string ) : Promise < void > {
783
- await t
784
- . click ( this . removeElementFromListIconButton )
773
+ await t . click ( this . removeElementFromListIconButton ) ;
785
774
//Enter count of the removing elements
786
- . typeText ( this . countInput , count , { replace : true , paste : true } )
775
+ await t . typeText ( this . countInput , count , { replace : true , paste : true } ) ;
787
776
//Select Remove from head selection
788
- . click ( this . removeElementFromListSelect )
789
- . click ( this . removeFromHeadSelection )
777
+ await t . click ( this . removeElementFromListSelect ) ;
778
+ await t . click ( this . removeFromHeadSelection ) ;
790
779
//Confirm removing
791
- . click ( this . removeElementFromListButton )
792
- . click ( this . confirmRemoveListElementButton ) ;
780
+ await t . click ( this . removeElementFromListButton ) ;
781
+ await t . click ( this . confirmRemoveListElementButton ) ;
793
782
}
794
783
795
784
/**
@@ -898,15 +887,14 @@ export class BrowserPage {
898
887
*/
899
888
async changeDelimiterInTreeView ( delimiter : string ) : Promise < void > {
900
889
// Open delimiter popup
901
- await t
902
- . click ( this . treeViewDelimiterButton )
890
+ await t . click ( this . treeViewDelimiterButton ) ;
903
891
// Check the previous value
904
- . expect ( this . treeViewDelimiterButton . withExactText ( ':' ) . exists ) . ok ( 'Default delimiter value not correct' )
892
+ await t . expect ( this . treeViewDelimiterButton . withExactText ( ':' ) . exists ) . ok ( 'Default delimiter value not correct' ) ;
905
893
// Apply new value to the field
906
- . typeText ( this . treeViewDelimiterInput , delimiter , { replace : true , paste : true } )
894
+ await t . typeText ( this . treeViewDelimiterInput , delimiter , { replace : true , paste : true } ) ;
907
895
// Click on save button
908
- . click ( this . treeViewDelimiterValueSave )
909
- . expect ( this . treeViewDelimiterButton . withExactText ( delimiter ) . exists ) . ok ( 'Delimiter is not changed' ) ;
896
+ await t . click ( this . treeViewDelimiterValueSave ) ;
897
+ await t . expect ( this . treeViewDelimiterButton . withExactText ( delimiter ) . exists ) . ok ( 'Delimiter is not changed' ) ;
910
898
}
911
899
912
900
//Delete entry from Stream key
0 commit comments