@@ -30,7 +30,7 @@ fixture `Default scripts area at Workbench`
30
30
//Drop index and documents
31
31
await workbenchPage . sendCommandInWorkbench ( 'FT.DROPINDEX products DD' ) ;
32
32
} )
33
- //skipped due the disabled default scripts area
33
+ //skipped due the inaccessibility of the iframe
34
34
test . skip ( 'Verify that user can edit and run automatically added "FT._LIST" and "FT.INFO {index}" scripts in Workbench and see the results' , async t => {
35
35
const commandsForSend = [
36
36
`FT.CREATE ${ indexName } ON HASH PREFIX 1 product: SCHEMA name TEXT` ,
@@ -40,33 +40,35 @@ test.skip('Verify that user can edit and run automatically added "FT._LIST" and
40
40
//Send commands
41
41
await workbenchPage . sendCommandInWorkbench ( commandsForSend . join ( '\n' ) ) ;
42
42
//Run automatically added "FT._LIST" script
43
+ await t . click ( workbenchPage . internalLinkWorkingWithHashes ) ;
43
44
await t . click ( workbenchPage . preselectList ) ;
44
45
await t . click ( workbenchPage . submitCommandButton ) ;
45
46
//Check the FT._LIST result
46
47
await t . expect ( workbenchPage . queryTextResult . textContent ) . contains ( indexName , 'The result of the FT._LIST command' ) ;
47
48
//Run automatically added "FT.INFO {index}" script with added index
48
49
await t . click ( workbenchPage . preselectIndexInfo ) ;
49
- let addedScript = await workbenchPage . queryInputScriptArea . textContent ;
50
+ let addedScript = await workbenchPage . queryInputScriptArea . nth ( 3 ) . textContent ;
50
51
//Replace the {index} with indexName value in script and send
51
- addedScript = addedScript . replace ( '{index} ' , indexName ) ;
52
+ addedScript = addedScript . replace ( '"permits" ' , indexName ) ;
52
53
addedScript = addedScript . replace ( / \s / g, ' ' ) ;
53
54
await t . pressKey ( 'ctrl+a delete' ) ;
54
55
await workbenchPage . sendCommandInWorkbench ( addedScript ) ;
55
56
//Check the FT.INFO result
56
57
await t . expect ( workbenchPage . queryColumns . textContent ) . contains ( 'name' , 'The result of the FT.INFO command' ) ;
57
58
} ) ;
58
- //skipped due the disabled default scripts area
59
+ //skipped due the inaccessibility of the iframe
59
60
test . skip ( 'Verify that user can edit and run automatically added "Search" script in Workbench and see the results' , async t => {
60
61
const commandsForSend = [
61
62
`FT.CREATE ${ indexName } ON HASH PREFIX 1 product: SCHEMA name TEXT` ,
62
63
'HMSET product:1 name "Apple Juice"' ,
63
64
'HMSET product:2 name "Apple Juice"'
64
65
] ;
65
- const searchCommand = `FT.SEARCH ${ indexName } * LIMIT 0 20 ` ;
66
+ const searchCommand = `FT.SEARCH " ${ indexName } " "Apple Juice" ` ;
66
67
//Send commands
67
68
await workbenchPage . sendCommandInWorkbench ( commandsForSend . join ( '\n' ) ) ;
68
69
//Run automatically added FT.SEARCH script with edits
69
- await t . click ( workbenchPage . preselectSearch ) ;
70
+ await t . click ( workbenchPage . internalLinkWorkingWithHashes ) ;
71
+ await t . click ( workbenchPage . preselectExactSearch ) ;
70
72
await t . pressKey ( 'ctrl+a delete' ) ;
71
73
await workbenchPage . sendCommandInWorkbench ( searchCommand ) ;
72
74
//Check the FT.SEARCH result
@@ -75,7 +77,7 @@ test.skip('Verify that user can edit and run automatically added "Search" script
75
77
await t . expect ( key . exists ) . ok ( 'The added key is in the Search result' ) ;
76
78
await t . expect ( name . exists ) . ok ( 'The added key name field is in the Search result' ) ;
77
79
} ) ;
78
- //skipped due the disabled default scripts area
80
+ //skipped due the inaccessibility of the iframe
79
81
test . skip ( 'Verify that user can edit and run automatically added "Aggregate" script in Workbench and see the results' , async t => {
80
82
const aggregationResultField = 'max_price' ;
81
83
const commandsForSend = [
@@ -87,7 +89,8 @@ test.skip('Verify that user can edit and run automatically added "Aggregate" scr
87
89
//Send commands
88
90
await workbenchPage . sendCommandInWorkbench ( commandsForSend . join ( '\n' ) , 0.5 ) ;
89
91
//Run automatically added FT.Aggregate script with edits
90
- await t . click ( workbenchPage . preselectSearch ) ;
92
+ await t . click ( workbenchPage . internalLinkWorkingWithHashes ) ;
93
+ await t . click ( workbenchPage . preselectGroupBy ) ;
91
94
await t . pressKey ( 'ctrl+a delete' ) ;
92
95
await workbenchPage . sendCommandInWorkbench ( searchCommand ) ;
93
96
//Check the FT.Aggregate result
0 commit comments