@@ -26,25 +26,25 @@ fixture `JSON verifications at Workbench`
26
26
await deleteStandaloneDatabaseApi ( ossStandaloneRedisearch ) ;
27
27
} ) ;
28
28
test
29
- . meta ( { env : env . desktop } ) ( 'Verify that user can see result in Table and Text view for JSON data types for FT.AGGREGATE command in Workbench' , async t => {
30
- indexName = common . generateWord ( 5 ) ;
31
- const commandsForSend = [
32
- `FT.CREATE ${ indexName } ON JSON SCHEMA $.user.name AS name TEXT $.user.tag AS country TAG` ,
33
- 'JSON.SET myDoc1 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":1000, "dmg":150}}\'' ,
34
- 'JSON.SET myDoc2 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":500, "dmg":300}}\''
35
- ] ;
36
- const searchCommand = `FT.AGGREGATE ${ indexName } "*" LOAD 6 $.user.hp AS hp $.user.dmg AS dmg APPLY "@hp-@dmg" AS points` ;
29
+ . meta ( { env : env . desktop } ) ( 'Verify that user can see result in Table and Text view for JSON data types for FT.AGGREGATE command in Workbench' , async t => {
30
+ indexName = common . generateWord ( 5 ) ;
31
+ const commandsForSend = [
32
+ `FT.CREATE ${ indexName } ON JSON SCHEMA $.user.name AS name TEXT $.user.tag AS country TAG` ,
33
+ 'JSON.SET myDoc1 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":1000, "dmg":150}}\'' ,
34
+ 'JSON.SET myDoc2 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":500, "dmg":300}}\''
35
+ ] ;
36
+ const searchCommand = `FT.AGGREGATE ${ indexName } "*" LOAD 6 $.user.hp AS hp $.user.dmg AS dmg APPLY "@hp-@dmg" AS points` ;
37
37
38
- // Send commands
39
- await workbenchPage . sendCommandInWorkbench ( commandsForSend . join ( '\n' ) ) ;
40
- // Send search command
41
- await workbenchPage . sendCommandInWorkbench ( searchCommand ) ;
42
- // Check that result is displayed in Table view
43
- await t . switchToIframe ( workbenchPage . iframe ) ;
44
- await t . expect ( workbenchPage . queryTableResult . exists ) . ok ( 'The result is displayed in Table view' ) ;
45
- // Select Text view type
46
- await t . switchToMainWindow ( ) ;
47
- await workbenchPage . selectViewTypeText ( ) ;
48
- // Check that result is displayed in Text view
49
- await t . expect ( workbenchPage . queryTextResult . exists ) . ok ( 'The result is displayed in Text view' ) ;
50
- } ) ;
38
+ // Send commands
39
+ await workbenchPage . sendCommandInWorkbench ( commandsForSend . join ( '\n' ) ) ;
40
+ // Send search command
41
+ await workbenchPage . sendCommandInWorkbench ( searchCommand ) ;
42
+ // Check that result is displayed in Table view
43
+ await t . switchToIframe ( workbenchPage . iframe ) ;
44
+ await t . expect ( workbenchPage . queryTableResult . exists ) . ok ( 'The result is displayed in Table view' ) ;
45
+ // Select Text view type
46
+ await t . switchToMainWindow ( ) ;
47
+ await workbenchPage . selectViewTypeText ( ) ;
48
+ // Check that result is displayed in Text view
49
+ await t . expect ( workbenchPage . queryTextResult . exists ) . ok ( 'The result is displayed in Text view' ) ;
50
+ } ) ;
0 commit comments