Skip to content
Merged
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
24 changes: 8 additions & 16 deletions tests/e2e/tests/smoke/browser/verify-key-details.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ const myRedisDatabasePage = new MyRedisDatabasePage();
const browserPage = new BrowserPage();
const userAgreementPage = new UserAgreementPage();
const addRedisDatabasePage = new AddRedisDatabasePage();
const keyTTL = '2147476121';
const expectedTTL = /214747612*/;

fixture `Key details verification`
.meta({ type: 'smoke' })
Expand All @@ -29,8 +31,6 @@ fixture `Key details verification`
})
test('Verify that user can see Hash Key details', async t => {
const keyName = 'Hash1testKeyForEdit';
const keyTTL = '2147476121';

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);

await browserPage.addHashKey(keyName, keyTTL);
Expand All @@ -42,13 +42,11 @@ test('Verify that user can see Hash Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('Hash', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('Hash', 'The Key Badge');
});
test('Verify that user can see List Key details', async t => {
const keyName = 'List1testKeyForEdit';
const keyTTL = '2147476121';

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);

await browserPage.addListKey(keyName, keyTTL);
Expand All @@ -60,13 +58,11 @@ test('Verify that user can see List Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('List', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('List', 'The Key Badge');
});
test('Verify that user can see Set Key details', async t => {
const keyName = 'Set1testKeyForEdit';
const keyTTL = '2147476121';

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);

await browserPage.addSetKey(keyName, keyTTL);
Expand All @@ -78,12 +74,11 @@ test('Verify that user can see Set Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('Set', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('Set', 'The Key Badge');
});
test('Verify that user can see String Key details', async t => {
const keyName = 'String1testKeyForEdit';
const keyTTL = '2147476121';
const value = 'keyValue12334353434;'

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);
Expand All @@ -97,13 +92,11 @@ test('Verify that user can see String Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('String', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('String', 'The Key Badge');
});
test('Verify that user can see ZSet Key details', async t => {
const keyName = 'ZSet1testKeyForEdit';
const keyTTL = '2147476121';

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);

await browserPage.addZSetKey(keyName, '1', keyTTL);
Expand All @@ -115,12 +108,11 @@ test('Verify that user can see ZSet Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('Sorted Set', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('Sorted Set', 'The Key Badge');
});
test('Verify that user can see JSON Key details', async t => {
const keyName = 'JSON1testKeyForEdit';
const keyTTL = '2147476121';
const jsonValue = '{"employee":{ "name":"John", "age":30, "city":"New York" }}';

await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);
Expand All @@ -134,6 +126,6 @@ test('Verify that user can see JSON Key details', async t => {
await t.expect(keyNameFromDetails).contains(keyName, 'The Key Name');
await t.expect(keyDetails).contains('JSON', 'The Key Type');
await t.expect(keyDetails).contains('TTL', 'The TTL');
await t.expect(keyTTLValue).contains(keyTTL, 'The Key TTL');
await t.expect(keyTTLValue).match(expectedTTL, 'The Key TTL');
await t.expect(keyBadge).contains('JSON', 'The Key Badge');
});