test(admin/e2e): Rename variables for clarity (#1878)

This commit is contained in:
Michael Li authored and GitHub committed 2023-09-06 10:49:09 -04:00
1 parent 61b81a3bb5
commit 0c80f4ba40
4 files changed
+10 -10

No files matched your search

+5 -5
View File
@@ -127,7 +127,7 @@ exports.createNewHostInHostSet = async (page) => {
await page.getByRole('link', { name: 'Create and Add Host' }).click();
await page.getByLabel('Name').fill(hostName);
await page.getByLabel('Description').fill('This is an automated test');
await page.getByLabel('Address').fill(process.env.E2E_TARGET_IP);
await page.getByLabel('Address').fill(process.env.E2E_TARGET_ADDRESS);
await page.getByRole('button', { name: 'Save' }).click();
await expect(
page.getByRole('alert').getByText('Success', { exact: true })
@@ -152,7 +152,7 @@ exports.createNewTarget = async (page) => {
await page.getByRole('link', { name: 'New' }).click();
await page.getByLabel('Name').fill(targetName);
await page.getByLabel('Description').fill('This is an automated test');
await page.getByLabel('Default Port').fill(process.env.E2E_SSH_PORT);
await page.getByLabel('Default Port').fill(process.env.E2E_TARGET_PORT);
await page.getByRole('button', { name: 'Save' }).click();
await expect(
page.getByRole('alert').getByText('Success', { exact: true })
@@ -181,8 +181,8 @@ exports.createNewTargetWithAddress = async (page) => {
await page.getByRole('link', { name: 'New' }).click();
await page.getByLabel('Name').fill(targetName);
await page.getByLabel('Description').fill('This is an automated test');
await page.getByLabel('Target Address').fill(process.env.E2E_TARGET_IP);
await page.getByLabel('Default Port').fill(process.env.E2E_SSH_PORT);
await page.getByLabel('Target Address').fill(process.env.E2E_TARGET_ADDRESS);
await page.getByLabel('Default Port').fill(process.env.E2E_TARGET_PORT);
await page.getByRole('button', { name: 'Save' }).click();
await expect(
page.getByRole('alert').getByText('Success', { exact: true })
@@ -323,7 +323,7 @@ exports.makeAuthMethodPrimary = async (page) => {
.getByRole('navigation', { name: 'IAM' })
.getByRole('link', { name: 'Auth Methods' })
.click();
await page.getByRole('button', { name: 'Manage' }).click()
await page.getByRole('button', { name: 'Manage' }).click();
await page.getByText('Make Primary', { exact: true }).click();
await page.getByText('OK', { exact: true }).click();
await expect(
@@ -28,10 +28,10 @@ test.use({ storageState: authenticatedState });
test.beforeAll(async () => {
await checkEnv([
'E2E_TARGET_IP',
'E2E_SSH_USER',
'E2E_SSH_KEY_PATH',
'E2E_SSH_PORT',
'E2E_TARGET_ADDRESS',
'E2E_TARGET_PORT',
]);
await checkBoundaryCli();
@@ -36,7 +36,7 @@ test.beforeAll(async () => {
'VAULT_ADDR', // Address used by Vault CLI
'VAULT_TOKEN',
'E2E_VAULT_ADDR', // Address used by Boundary Server (could be different from VAULT_ADDR depending on network config (i.e. docker network))
'E2E_TARGET_IP',
'E2E_TARGET_ADDRESS',
'E2E_SSH_USER',
'E2E_SSH_KEY_PATH',
]);
+2 -2
View File
@@ -29,10 +29,10 @@ test.use({ storageState: authenticatedState });
test.beforeAll(async () => {
await checkEnv([
'E2E_TARGET_IP',
'E2E_SSH_USER',
'E2E_SSH_KEY_PATH',
'E2E_SSH_PORT',
'E2E_TARGET_ADDRESS',
'E2E_TARGET_PORT',
]);
await checkBoundaryCli();