Skip to content

Commit 3d2cf13

Browse files
committed
change db to tls
1 parent 44ba1cd commit 3d2cf13

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

tests/e2e/tests/web/critical-path/database/encryption.e2e.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { rte } from '../../../../helpers/constants';
22
import { MyRedisDatabasePage } from '../../../../pageObjects';
33
import {
44
commonUrl,
5-
ossStandaloneConfig
5+
ossStandaloneTlsConfig
66
} from '../../../../helpers/conf';
77
import { DatabaseHelper } from '../../../../helpers/database';
88
import { DatabaseAPIRequests } from '../../../../helpers/api/api-database';
@@ -17,29 +17,30 @@ const dbTableParams: DbTableParameters = {
1717
columnName: 'caCertId',
1818
rowValue: 'invalid',
1919
conditionColumnName: 'name',
20-
conditionColumnValue: ossStandaloneConfig.databaseName
20+
conditionColumnValue: ossStandaloneTlsConfig.databaseName
2121
};
2222

2323
fixture `Encryption`
2424
.meta({ type: 'critical_path', rte: rte.none })
2525
.page(commonUrl)
2626
.beforeEach(async() => {
2727
await databaseHelper.acceptLicenseTerms();
28-
await databaseAPIRequests.addNewStandaloneDatabaseApi(ossStandaloneConfig);
28+
await databaseAPIRequests.addNewStandaloneDatabaseApi(ossStandaloneTlsConfig);
2929
await myRedisDatabasePage.reloadPage();
3030
})
3131
.afterEach(async() => {
32-
await databaseHelper.deleteDatabase(ossStandaloneConfig.databaseName);
32+
await databaseHelper.deleteDatabase(ossStandaloneTlsConfig.databaseName);
3333
});
3434
test('Verify that data encrypted using KEY', async t => {
3535
const decryptionError = 'Unable to decrypt data';
3636
// Connect to DB
37-
await myRedisDatabasePage.clickOnDBByName(ossStandaloneConfig.databaseName);
37+
await myRedisDatabasePage.clickOnDBByName(ossStandaloneTlsConfig.databaseName);
38+
// Return back to db list page
3839
await t.click(myRedisDatabasePage.NavigationPanel.myRedisDBButton);
3940

4041
await DatabaseScripts.updateColumnValueInDBTable(dbTableParams);
4142
// Verify that Encription by KEY applied for connection if RI_ENCRYPTION_KEY variable exists
42-
await t.expect(await DatabaseScripts.getColumnValueFromTableInDB({ ...dbTableParams, columnName: 'encryption' })).eql('KEY', 'Encription is not applied by Key');
43-
await databaseHelper.clickOnEditDatabaseByName(ossStandaloneConfig.databaseName);
43+
await t.expect(await DatabaseScripts.getColumnValueFromTableInDB({ ...dbTableParams, columnName: 'encryption' })).eql('KEY', 'Encription is not applied by RI_ENCRYPTION_KEY');
44+
await databaseHelper.clickOnEditDatabaseByName(ossStandaloneTlsConfig.databaseName);
4445
await t.expect(myRedisDatabasePage.Toast.toastError.textContent).contains(decryptionError, 'Invalid encrypted field is decrypted');
4546
});

0 commit comments

Comments
 (0)