Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 16 additions & 35 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -949,31 +949,12 @@ workflows:
name: Build docker image
requires:
- Start E2E Tests
# build desktop app
# - setup-sign-certificates:
# name: Setup sign certificates (stage)
# requires:
# - Start E2E Tests
# - setup-build:
# name: Setup build (stage)
# requires:
# - Setup sign certificates (stage)
# - windows:
# name: Build app - Windows (stage)
# requires:
# - Setup build (stage)
- e2e-tests:
name: E2ETest
build: docker
parallelism: 4
requires:
- Build docker image
# - e2e-exe:
# name: E2ETest (exe)
# parallelism: 1
# report: true
# requires:
# - Build app - Windows (stage)
# Workflow for feature, bugfix, main branches
feature-main-branch:
jobs:
Expand Down Expand Up @@ -1239,16 +1220,16 @@ workflows:
- docker:
name: Build docker image
# build desktop app
# - setup-sign-certificates:
# name: Setup sign certificates (stage)
# - setup-build:
# name: Setup build (stage)
# requires:
# - Setup sign certificates (stage)
# - linux:
# name: Build app - Linux (stage)
# requires:
# - Setup build (stage)
- setup-sign-certificates:
name: Setup sign certificates (stage)
- setup-build:
name: Setup build (stage)
requires:
- Setup sign certificates (stage)
- linux:
name: Build app - Linux (stage)
requires:
- Setup build (stage)
# - windows:
# name: Build app - Windows (stage)
# requires:
Expand All @@ -1273,12 +1254,12 @@ workflows:
requires:
- Build docker image
# e2e desktop tests on AppImage build
# - e2e-app-image:
# name: E2ETest (AppImage) - Nightly
# parallelism: 4
# report: true
# requires:
# - Build app - Linux (stage)
- e2e-app-image:
name: E2ETest (AppImage) - Nightly
parallelism: 2
report: true
requires:
- Build app - Linux (stage)
# # e2e desktop tests on exe build
# - e2e-exe:
# name: E2ETest (exe) - Nightly
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/desktop.runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import testcafe from 'testcafe';
.screenshots({
path: 'report/screenshots/',
takeOnFails: true,
pathPattern: '${USERAGENT}/${DATE}_${TIME}/${FIXTURE}_${FILE_INDEX}.png',
pathPattern: '${USERAGENT}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png',
})
.reporter([
'spec',
Expand Down
2 changes: 1 addition & 1 deletion tests/e2e/desktop.runner.win.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import testcafe from 'testcafe';
.screenshots({
path: 'report/screenshots/',
takeOnFails: true,
pathPattern: '${USERAGENT}/${DATE}_${TIME}/${FIXTURE}_${FILE_INDEX}.png',
pathPattern: '${USERAGENT}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png',
})
.reporter([
'spec',
Expand Down
7 changes: 4 additions & 3 deletions tests/e2e/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
"name": "redisinsight",
"version": "1.0.0",
"description": "End-to-end tests",
"private": true,
"main": "index.js",
"scripts": {
"test:live": "testcafe --live chrome ",
Expand All @@ -12,13 +13,13 @@
"build:web": "yarn --cwd ../../ build:web",
"redis:last": "docker run --name redis-last-version -p 7777:6379 -d redislabs/redismod",
"start:app": "cross-env SERVER_STATIC_CONTENT=true yarn start:api",
"test:chrome": "testcafe --compiler-options typescript.configPath=tsconfig.testcafe.json --cache --concurrency 1 chrome tests/ -r html:./report/report.html,spec -e -s takeOnFails=true,path=report/screenshots,pathPattern=${OS}_${BROWSER}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png",
"test:chrome": "testcafe --compiler-options typescript.configPath=tsconfig.testcafe.json --cache --concurrency 1 chrome tests/ -r html:./report/report.html,spec -e -s takeOnFails=true,path=report/screenshots/,pathPattern=${OS}_${BROWSER}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png",
"test:chrome:ci": "ts-node ./web.runner.ts",
"test": "yarn test:chrome",
"lint": "eslint . --ext .ts,.js,.tsx,.jsx",
"test:desktop:ci": "ts-node ./desktop.runner.ts",
"test:desktop:ci:win": "ts-node ./desktop.runner.win.ts",
"test:desktop": "testcafe electron tests/ --compiler-options typescript.configPath=tsconfig.testcafe.json --browser-init-timeout 180000 -e -r html:./report/desktop-report.html,spec -s takeOnFails=true,path=report/screenshots,pathPattern=${OS}_${BROWSER}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png"
"test:desktop": "testcafe electron tests/ --compiler-options typescript.configPath=tsconfig.testcafe.json --browser-init-timeout 180000 -e -r html:./report/desktop-report.html,spec -s takeOnFails=true,path=report/screenshots/,pathPattern=${OS}_${BROWSER}/${DATE}_${TIME}/${FIXTURE}_${TEST}_${FILE_INDEX}.png"
},
"keywords": [],
"author": "",
Expand Down Expand Up @@ -52,6 +53,6 @@
"testcafe-reporter-json": "2.2.0",
"testcafe-reporter-spec": "2.1.1",
"ts-node": "^10.5.0",
"typescript": "5.0.4"
"typescript": "4.1.5"
}
}
80 changes: 40 additions & 40 deletions tests/e2e/tests/critical-path/workbench/index-schema.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,46 +25,46 @@ fixture `Index Schema at Workbench`
await deleteStandaloneDatabaseApi(ossStandaloneRedisearch);
});
test
.meta({ env: env.desktop })('Verify that user can open results in Text and Table views for FT.INFO for Hash in Workbench', async t => {
indexName = Common.generateWord(5);
const commandsForSend = [
`FT.CREATE ${indexName} ON HASH PREFIX 1 product: SCHEMA name TEXT`,
'HMSET product:1 name "Apple Juice"'
];
const searchCommand = `FT.INFO ${indexName}`;
.meta({ env: env.desktop })('Verify that user can open results in Text and Table views for FT.INFO for Hash in Workbench', async t => {
indexName = Common.generateWord(5);
const commandsForSend = [
`FT.CREATE ${indexName} ON HASH PREFIX 1 product: SCHEMA name TEXT`,
'HMSET product:1 name "Apple Juice"'
];
const searchCommand = `FT.INFO ${indexName}`;

// Send commands
await workbenchPage.sendCommandInWorkbench(commandsForSend.join('\n'));
// Send search command
await workbenchPage.sendCommandInWorkbench(searchCommand);
// Check that result is displayed in Table view
await t.switchToIframe(workbenchPage.iframe);
await t.expect(workbenchPage.queryTableResult.exists).ok('The result is displayed in Table view');
// Select Text view type
await t.switchToMainWindow();
await workbenchPage.selectViewTypeText();
// Check that result is displayed in Text view
await t.expect(workbenchPage.queryTextResult.exists).ok('The result is displayed in Text view');
});
// Send commands
await workbenchPage.sendCommandInWorkbench(commandsForSend.join('\n'));
// Send search command
await workbenchPage.sendCommandInWorkbench(searchCommand);
// Check that result is displayed in Table view
await t.switchToIframe(workbenchPage.iframe);
await t.expect(workbenchPage.queryTableResult.exists).ok('The result is displayed in Table view');
// Select Text view type
await t.switchToMainWindow();
await workbenchPage.selectViewTypeText();
// Check that result is displayed in Text view
await t.expect(workbenchPage.queryTextResult.exists).ok('The result is displayed in Text view');
});
test
.meta({ env: env.desktop })('Verify that user can open results in Text and Table views for FT.INFO for JSON in Workbench', async t => {
indexName = Common.generateWord(5);
const commandsForSend = [
`FT.CREATE ${indexName} ON JSON SCHEMA $.user.name AS name TEXT $.user.tag AS country TAG`,
'JSON.SET myDoc1 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":1000, "dmg":150}}\''
];
const searchCommand = `FT.INFO ${indexName}`;
.meta({ env: env.desktop })('Verify that user can open results in Text and Table views for FT.INFO for JSON in Workbench', async t => {
indexName = Common.generateWord(5);
const commandsForSend = [
`FT.CREATE ${indexName} ON JSON SCHEMA $.user.name AS name TEXT $.user.tag AS country TAG`,
'JSON.SET myDoc1 $ \'{"user":{"name":"John Smith","tag":"foo,bar","hp":1000, "dmg":150}}\''
];
const searchCommand = `FT.INFO ${indexName}`;

// Send commands
await workbenchPage.sendCommandInWorkbench(commandsForSend.join('\n'));
// Send search command
await workbenchPage.sendCommandInWorkbench(searchCommand);
// Check that result is displayed in Table view
await t.switchToIframe(workbenchPage.iframe);
await t.expect(workbenchPage.queryTableResult.exists).ok('The result is displayed in Table view');
// Select Text view type
await t.switchToMainWindow();
await workbenchPage.selectViewTypeText();
// Check that result is displayed in Text view
await t.expect(workbenchPage.queryTextResult.exists).ok('The result is displayed in Text view');
});
// Send commands
await workbenchPage.sendCommandInWorkbench(commandsForSend.join('\n'));
// Send search command
await workbenchPage.sendCommandInWorkbench(searchCommand);
// Check that result is displayed in Table view
await t.switchToIframe(workbenchPage.iframe);
await t.expect(workbenchPage.queryTableResult.exists).ok('The result is displayed in Table view');
// Select Text view type
await t.switchToMainWindow();
await workbenchPage.selectViewTypeText();
// Check that result is displayed in Text view
await t.expect(workbenchPage.queryTextResult.exists).ok('The result is displayed in Text view');
});
7 changes: 6 additions & 1 deletion tests/e2e/tests/regression/database/edit-db.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,13 @@ test
.before(async() => {
await acceptLicenseTermsAndAddDatabaseApi(ossStandaloneConfig, ossStandaloneConfig.databaseName);
})
.after(async() => {
.after(async t => {
// Clear and delete database
await t.click(myRedisDatabasePage.NavigationPanel.myRedisDBButton);
await clickOnEditDatabaseByName(ossStandaloneConfig.databaseName);
await t.typeText(myRedisDatabasePage.AddRedisDatabase.portInput, ossStandaloneConfig.port, { replace: true, paste: true });
await t.click(myRedisDatabasePage.AddRedisDatabase.addRedisDatabaseButton);
await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);
await browserPage.deleteKeyByName(keyName);
await deleteStandaloneDatabaseApi(ossStandaloneConfig);
})('Verify that context for previous database not saved after editing port/username/password/certificates/SSH', async t => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,8 @@ test
await t.switchToMainWindow();
await workbenchPage.selectViewTypeText();
await t.expect(workbenchPage.queryTextResult.exists).ok('The result in text view is not displayed');
// Verify that when there is nothing to visualize in RedisGraph, user can see: No data to visualize.{results from the text view}
await t.expect(workbenchPage.queryTextResult.textContent).eql(graphModeText, 'Text of command in Graph mode is not the same as in Text mode');
// Verify that when there is nothing to visualize in RedisGraph, user can see just text result
await t.expect(workbenchPage.queryTextResult.textContent).notEql(graphModeText, 'Text of command in Graph mode is the same as in Text mode');
});
test('Verify that user can switches between Chart and Text for TimeSeries command and see results corresponding to their views', async t => {
// Send TimeSeries command
Expand Down
40 changes: 5 additions & 35 deletions tests/e2e/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5699,36 +5699,6 @@ testcafe-hammerhead@24.2.1:
tunnel-agent "0.6.0"
webauth "^1.1.0"

testcafe-hammerhead@>=19.4.0:
version "31.3.0"
resolved "https://registry.yarnpkg.com/testcafe-hammerhead/-/testcafe-hammerhead-31.3.0.tgz#6ab36f861b6e90f4c884751623cd4cc95150d0ba"
integrity sha512-bTy9qL4jtmNr1+ATleWX+I2JC4BA83WV0X6SBXiFovCHg84RkSdqoj2n4LQp6WEzDm5RV3eV+P+kToH/XYywnw==
dependencies:
"@electron/asar" "^3.2.3"
acorn-hammerhead "0.6.1"
bowser "1.6.0"
crypto-md5 "^1.0.0"
css "2.2.3"
debug "4.3.1"
esotope-hammerhead "0.6.4"
http-cache-semantics "^4.1.0"
httpntlm "^1.8.10"
iconv-lite "0.5.1"
lodash "^4.17.20"
lru-cache "2.6.3"
match-url-wildcard "0.0.4"
merge-stream "^1.0.1"
mime "~1.4.1"
mustache "^2.1.1"
nanoid "^3.1.12"
os-family "^1.0.0"
parse5 "2.2.3"
pinkie "2.0.4"
read-file-relative "^1.2.0"
semver "5.5.0"
tough-cookie "4.0.0"
tunnel-agent "0.6.0"

testcafe-legacy-api@5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/testcafe-legacy-api/-/testcafe-legacy-api-5.0.0.tgz#dde9dc2ee9e9490afed58b83df23cf2e01a6c303"
Expand All @@ -5747,7 +5717,7 @@ testcafe-legacy-api@5.0.0:
pinkie "^2.0.1"
read-file-relative "^1.2.0"
strip-bom "^2.0.0"
testcafe-hammerhead ">=19.4.0"
testcafe-hammerhead "24.2.1"

testcafe-reporter-html@1.4.6:
version "1.4.6"
Expand Down Expand Up @@ -6058,10 +6028,10 @@ typed-array-length@^1.0.4:
for-each "^0.3.3"
is-typed-array "^1.1.9"

typescript@5.0.4:
version "5.0.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.4.tgz#b217fd20119bd61a94d4011274e0ab369058da3b"
integrity sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==
typescript@4.1.5:
version "4.1.5"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.1.5.tgz#123a3b214aaff3be32926f0d8f1f6e704eb89a72"
integrity sha512-6OSu9PTIzmn9TCDiovULTnET6BgXtDYL4Gg4szY+cGsc3JP1dQL8qvE8kShTRx1NIw4Q9IBHlwODjkjWEtMUyA==

typescript@^3.3.3:
version "3.9.10"
Expand Down