diff --git a/tests/e2e/tests/critical-path/cli/cli-command-helper.e2e.ts b/tests/e2e/tests/critical-path/cli/cli-command-helper.e2e.ts index 8a7ecc0918..71e34fa2af 100644 --- a/tests/e2e/tests/critical-path/cli/cli-command-helper.e2e.ts +++ b/tests/e2e/tests/critical-path/cli/cli-command-helper.e2e.ts @@ -73,7 +73,7 @@ test('Verify Command Helper search and filter', async t => { // Verify that when user enters command in CLI, Helper displays additional info about the command await t.expect(cliPage.cliHelperTitleArgs.textContent).eql('APPEND key value', 'Command name and syntax not displayed'); await t.expect(cliPage.cliHelperTitle.innerText).contains('STRING', 'Command Group badge not displayed'); - await t.expect(cliPage.cliHelperSummary.innerText).contains('Append a value to a key', 'Command summary not displayed'); + await t.expect(cliPage.cliHelperSummary.innerText).contains(`Appends a string to the value of a key. Creates the key if it doesn't exist.`, 'Command summary not displayed'); }); test .meta({ env: env.web })('Verify that user can type TS. in Command helper and see commands from RedisTimeSeries commands.json', async t => { diff --git a/tests/e2e/tests/critical-path/workbench/redisearch-module-not-available.e2e.ts b/tests/e2e/tests/critical-path/workbench/redisearch-module-not-available.e2e.ts index bef89f95d1..186acdd902 100644 --- a/tests/e2e/tests/critical-path/workbench/redisearch-module-not-available.e2e.ts +++ b/tests/e2e/tests/critical-path/workbench/redisearch-module-not-available.e2e.ts @@ -25,5 +25,5 @@ test('Verify that user can see the information message that the RediSearch modul // Send command with 'FT.' await workbenchPage.sendCommandInWorkbench(commandForSend); // Verify the information message - await t.expect(await workbenchPage.queryCardNoModuleOutput.textContent).eql('RediSearch module is not loaded for this database', 'The information message'); + await t.expect(await workbenchPage.commandExecutionResult.textContent).eql('Looks like RediSearch is not available', 'The information message'); }); diff --git a/tests/e2e/tests/regression/workbench/autocomplete.e2e.ts b/tests/e2e/tests/regression/workbench/autocomplete.e2e.ts index 2e80509778..6aa4a9a7d7 100644 --- a/tests/e2e/tests/regression/workbench/autocomplete.e2e.ts +++ b/tests/e2e/tests/regression/workbench/autocomplete.e2e.ts @@ -23,7 +23,8 @@ test('Verify that user can open the "read more" about the command by clicking on const command = 'HSET'; const commandDetails = [ 'HSET key data [data ...]', - 'Set the string value of a hash field', + 'Creates or modifies the value of a field in a hash.', + 'Read more', 'Arguments:', 'required key', 'multiple data' diff --git a/tests/e2e/tests/regression/workbench/command-results.e2e.ts b/tests/e2e/tests/regression/workbench/command-results.e2e.ts index a68bba1d54..da2dc908eb 100644 --- a/tests/e2e/tests/regression/workbench/command-results.e2e.ts +++ b/tests/e2e/tests/regression/workbench/command-results.e2e.ts @@ -2,7 +2,7 @@ import { acceptLicenseTermsAndAddDatabaseApi } from '../../../helpers/database'; import { WorkbenchPage, MyRedisDatabasePage } from '../../../pageObjects'; import { commonUrl, - ossStandaloneRedisearch, ossStandaloneV5Config + ossStandaloneRedisearch } from '../../../helpers/conf'; import { env, rte } from '../../../helpers/constants'; import { deleteStandaloneDatabaseApi } from '../../../helpers/api/api-database'; @@ -118,37 +118,20 @@ test('Big output in workbench is visible in virtualized table', async t => { // Verify that all commands scrolled await t.expect(lastExpectedItem.visible).ok('Final execution time message not displayed'); }); - -test.before(async t => { - await acceptLicenseTermsAndAddDatabaseApi(ossStandaloneRedisearch, ossStandaloneRedisearch.databaseName); - await t.click(myRedisDatabasePage.workbenchButton); -}).after(async t => { - await t.switchToMainWindow(); - await deleteStandaloneDatabaseApi(ossStandaloneRedisearch); -})('Verify that user can see the client List visualization available for all users', async t => { - const command = 'CLIENT LIST'; - // Send command in workbench to view client list - await workbenchPage.sendCommandInWorkbench(command); - await t.expect(workbenchPage.typeSelectedClientsList.visible).ok('client list view button is not visible'); - await workBenchActions.verifyClientListColumnsAreVisible(['id', 'addr', 'name', 'user']); - // verify table view row count match with text view after client list command - await workBenchActions.verifyClientListTableViewRowCount(); -}); -// https://redislabs.atlassian.net/browse/RI-4230 -test.before(async t => { - await acceptLicenseTermsAndAddDatabaseApi(ossStandaloneV5Config, ossStandaloneV5Config.databaseName); - await t.click(myRedisDatabasePage.workbenchButton); -}).after(async() => { - await deleteStandaloneDatabaseApi(ossStandaloneV5Config); -})('Verify that user can see options on what can be done to work with capabilities in Workbench for docker', async t => { - const commandJSON = 'JSON.ARRAPPEND key value'; - const commandFT = 'FT.LIST'; - await workbenchPage.sendCommandInWorkbench(commandJSON); - // Verify change screens when capability not available - 'Search' - await t.expect(workbenchPage.welcomePageTitle.withText('Looks like RedisJSON is not available').visible) - .ok('Missing RedisJSON title is not visible'); - await workbenchPage.sendCommandInWorkbench(commandFT); - // Verify change screens when capability not available - 'JSON' - await t.expect(workbenchPage.welcomePageTitle.withText('Looks like RediSearch is not available').visible) - .ok('Missing RedisJSON title is not visible'); -}); +test + .before(async t => { + await acceptLicenseTermsAndAddDatabaseApi(ossStandaloneRedisearch, ossStandaloneRedisearch.databaseName); + await t.click(myRedisDatabasePage.workbenchButton); + }) + .after(async t => { + await t.switchToMainWindow(); + await deleteStandaloneDatabaseApi(ossStandaloneRedisearch); + })('Verify that user can see the client List visualization available for all users', async t => { + const command = 'CLIENT LIST'; + // Send command in workbench to view client list + await workbenchPage.sendCommandInWorkbench(command); + await t.expect(workbenchPage.typeSelectedClientsList.visible).ok('client list view button is not visible'); + await workBenchActions.verifyClientListColumnsAreVisible(['id', 'addr', 'name', 'user']); + // verify table view row count match with text view after client list command + await workBenchActions.verifyClientListTableViewRowCount(); + }); diff --git a/tests/e2e/tests/regression/workbench/redisearch-module-not-available.e2e.ts b/tests/e2e/tests/regression/workbench/redisearch-module-not-available.e2e.ts index f6e2d1ec05..4240ee283c 100644 --- a/tests/e2e/tests/regression/workbench/redisearch-module-not-available.e2e.ts +++ b/tests/e2e/tests/regression/workbench/redisearch-module-not-available.e2e.ts @@ -23,7 +23,8 @@ fixture `Redisearch module not available` // Delete database await deleteStandaloneDatabaseApi(ossStandaloneV5Config); }); -test +// Skipped as outdated after implementing RI-4230 +test.skip .meta({ env: env.web, rte: rte.standalone })('Verify that user can see the "Create your free Redis database with RediSearch on Redis Cloud" button and click on it in Workbench when module in not loaded', async t => { const link = 'https://redis.com/try-free/?utm_source=redis&utm_medium=app&utm_campaign=redisinsight_redisearch'; @@ -36,3 +37,24 @@ test await t.expect(getPageUrl()).contains(link, 'The Try Redis Enterprise page is not opened'); await t.switchToParentWindow(); }); +// https://redislabs.atlassian.net/browse/RI-4230 +test + .meta({ env: env.web, rte: rte.standalone }) + .before(async t => { + await acceptLicenseTermsAndAddDatabaseApi(ossStandaloneV5Config, ossStandaloneV5Config.databaseName); + await t.click(myRedisDatabasePage.workbenchButton); + }) + .after(async() => { + await deleteStandaloneDatabaseApi(ossStandaloneV5Config); + })('Verify that user can see options on what can be done to work with capabilities in Workbench for docker', async t => { + const commandJSON = 'JSON.ARRAPPEND key value'; + const commandFT = 'FT.LIST'; + await workbenchPage.sendCommandInWorkbench(commandJSON); + // Verify change screens when capability not available - 'Search' + await t.expect(workbenchPage.welcomePageTitle.withText('Looks like RedisJSON is not available').visible) + .ok('Missing RedisJSON title is not visible'); + await workbenchPage.sendCommandInWorkbench(commandFT); + // Verify change screens when capability not available - 'JSON' + await t.expect(workbenchPage.welcomePageTitle.withText('Looks like RediSearch is not available').visible) + .ok('Missing RedisJSON title is not visible'); + }); diff --git a/tests/e2e/tests/smoke/cli/cli-command-helper.e2e.ts b/tests/e2e/tests/smoke/cli/cli-command-helper.e2e.ts index 46c928faa5..b3cf7647ea 100644 --- a/tests/e2e/tests/smoke/cli/cli-command-helper.e2e.ts +++ b/tests/e2e/tests/smoke/cli/cli-command-helper.e2e.ts @@ -58,7 +58,7 @@ test('Verify that user can click on any of searched commands in Command Helper a // Verify details of the command await t.expect(cliPage.cliHelperTitleArgs.textContent).eql('APPEND key value', 'Command name and syntax not correct'); await t.expect(cliPage.cliHelperTitle.innerText).contains('STRING', 'Command Group badge not correct'); - await t.expect(cliPage.cliHelperSummary.innerText).contains('Append a value to a key Read more', 'Command summary not correct'); + await t.expect(cliPage.cliHelperSummary.innerText).contains(`Appends a string to the value of a key. Creates the key if it doesn't exist.`, 'Command summary not correct'); }); test('Verify that when user enters command, he can see Command Name, Complexity, Arguments, Summary, Group, Read more', async t => { const commandForSearch = 'pop'; @@ -73,7 +73,7 @@ test('Verify that when user enters command, he can see Command Name, Complexity, await t.expect(cliPage.cliHelperTitleArgs.innerText).eql('LPOP key [count]', 'Command Name not correct'); await t.expect(cliPage.cliHelperComplexity.innerText).eql('Complexity:\nO(N) where N is the number of elements returned', 'Complexity not correct'); await t.expect(cliPage.cliHelperArguments.innerText).eql('Arguments:\nRequired\nkey\nOptional\n[count]', 'Arguments not correct'); - await t.expect(cliPage.cliHelperSummary.innerText).contains('Remove and get the first elements in a list', 'Command Summary not correct'); + await t.expect(cliPage.cliHelperSummary.innerText).contains('Returns the first elements in a list after removing it. Deletes the list if the last element was popped.', 'Command Summary not correct'); await t.expect(cliPage.cliHelperTitle.innerText).contains('LIST', 'Command Group not correct'); await t.expect(cliPage.readMoreButton.exists).ok('Read more button not displayed'); });