+1





![hashicorp-copywrite[bot]](/avatar/120e964899bc27ee3737fc0cc3585755e19422fe9bff82b60b4b0c13d481706c?size=40)

![dependabot[bot]](/avatar/bd5a8d6c673b738d52b0ac42a110045f3f964b3ebfc1d60ea805af743b1dc0e6?size=40)
2d5323b07a
* fix: 🐛 add model hook to host route for dynamic host catalogs (#1659) * fix: 🐛 add model hook to host route for dynamic host catalogs ✅ Closes: ICU-8594 * refactor: 💡 remove page formatting for host route * [COMPLIANCE] Add Copyright and License Headers (#1660) Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com> Co-authored-by: Carlos Alcaide Corvo <ccorvo@hashicorp.com> * chore(deps-dev): bump webpack from 5.59.1 to 5.76.0 (#1654) Bumps [webpack](https://github.com/webpack/webpack) from 5.59.1 to 5.76.0. - [Release notes](https://github.com/webpack/webpack/releases) - [Commits](https://github.com/webpack/webpack/compare/v5.59.1...v5.76.0) --- updated-dependencies: - dependency-name: webpack dependency-type: direct:development ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Randall Morey <randall@randallmorey.com> Co-authored-by: Carlos Alcaide Corvo <ccorvo@hashicorp.com> * Feature metadata (#1661) * feat: 🎸 load edition from controller-metadata.json * refactor: 💡 rename edition and add licensed features support * chore: 🤖 support dev toggling of licensed features * chore: 🤖 rename ent edition * Update ui/admin/app/services/feature-edition.js * Update ui/admin/app/instance-initializers/feature-edition.js Co-authored-by: Zhihe Li <zhihe.li@hashicorp.com> * chore: 🤖 cleanup * chore: 🤖 feature edition disabled in tests / fix test cases * test: 💍 remove feature disable calls in tests * test: 💍 fix broken tests * fix: 🐛 fix config bug * fix: 🐛 fix broken test due to feature flags --------- Co-authored-by: Zhihe Li <zhihe.li@hashicorp.com> * fix: 🐛 Fix missing translation (#1662) Fix missing translation on the toggle color theme selector * Resolutions audit: Delete 3 oldest resolutions (#1663) * Delete bl from resolutions * Delete tough-cookie from resolutions * Delete npm from resolutions * chore(deps): bump http-cache-semantics from 4.1.0 to 4.1.1 (#1665) Bumps [http-cache-semantics](https://github.com/kornelski/http-cache-semantics) from 4.1.0 to 4.1.1. - [Release notes](https://github.com/kornelski/http-cache-semantics/releases) - [Commits](https://github.com/kornelski/http-cache-semantics/compare/v4.1.0...v4.1.1) --- updated-dependencies: - dependency-name: http-cache-semantics dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore: 🤖 Update electron-forge/* packages (#1666) Update electron-forge/* packages * feat: 🎸 Add support to display external name for dynamic hosts (#1664) * feat: 🎸 Add support to display external name for dynamic hosts ✅ Closes: ICU-8795 * test(admin/e2e): Add create target with address test (#1667) * chore: 🤖 update design system package (#1668) * test(admin/e2e): Define expected private key for vault credential store test (#1671) * test: 💍 (admin-e2e): Add test to create different credentials (#1670) * chore: 🤖 add json5 to resolutions per dependabot alerts (#1672) * chore: 🤖 add json5 to resolutions per dependabot alerts * fix: 🐛 remove unecessary resolutions * chore: 🤖 upgrade @storybook/ember-cli-storybook to 0.6.0 (#1669) * chore: 🤖 update @storybook/ember-cli-storybook to 0.6.0 ✅ Closes: ICU-6588 * chore: 🤖 remove css-what from resolutions * refactor: 💡 update selector for delete storage bucket test * chore: 🤖 fix yarn.lock --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: lisbet-alvarez <107949262+lisbet-alvarez@users.noreply.github.com> Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com> Co-authored-by: Carlos Alcaide Corvo <ccorvo@hashicorp.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Randall Morey <randall@randallmorey.com> Co-authored-by: Zhihe Li <zhihe.li@hashicorp.com> Co-authored-by: github-team-secure-boundary <hc-github-team-secure-boundary@hashicorp.com> Co-authored-by: hc-github-team-secure-boundary <82989682+hc-github-team-secure-boundary@users.noreply.github.com> Co-authored-by: Stan Ryzhov <60649800+stasryzhov@users.noreply.github.com> Co-authored-by: Dharini Jeeva <dharini@hashicorp.com>
122 lines
3.5 KiB
JavaScript
122 lines
3.5 KiB
JavaScript
/**
|
|
* Copyright (c) HashiCorp, Inc.
|
|
* SPDX-License-Identifier: MPL-2.0
|
|
*/
|
|
|
|
/* eslint-disable no-undef */
|
|
const { test } = require('@playwright/test');
|
|
const { execSync } = require('child_process');
|
|
const { checkEnv, authenticatedState } = require('../helpers/general');
|
|
const {
|
|
authenticateBoundaryCli,
|
|
checkBoundaryCli,
|
|
connectToTarget,
|
|
deleteOrg,
|
|
} = require('../helpers/boundary-cli');
|
|
const {
|
|
createNewOrg,
|
|
createNewProject,
|
|
createNewHostCatalog,
|
|
createNewHostSet,
|
|
createNewHostInHostSet,
|
|
createNewTarget,
|
|
createNewTargetWithAddress,
|
|
waitForSessionToBeVisible,
|
|
addHostSourceToTarget,
|
|
} = require('../helpers/boundary-ui');
|
|
|
|
test.use({ storageState: authenticatedState });
|
|
|
|
test.beforeAll(async () => {
|
|
await checkEnv([
|
|
'E2E_TARGET_IP',
|
|
'E2E_SSH_USER',
|
|
'E2E_SSH_KEY_PATH',
|
|
'E2E_SSH_PORT',
|
|
]);
|
|
|
|
await checkBoundaryCli();
|
|
});
|
|
|
|
test('Verify session created to target with host, then cancel the session', async ({
|
|
page,
|
|
}) => {
|
|
await page.goto('/');
|
|
let org;
|
|
let connect;
|
|
try {
|
|
const orgName = await createNewOrg(page);
|
|
const projectName = await createNewProject(page);
|
|
await createNewHostCatalog(page);
|
|
const hostSetName = await createNewHostSet(page);
|
|
await createNewHostInHostSet(page);
|
|
const targetName = await createNewTarget(page);
|
|
await addHostSourceToTarget(page, hostSetName);
|
|
|
|
await authenticateBoundaryCli();
|
|
const orgs = JSON.parse(execSync('boundary scopes list -format json'));
|
|
org = orgs.items.filter((obj) => obj.name == orgName)[0];
|
|
const projects = JSON.parse(
|
|
execSync('boundary scopes list -format json -scope-id ' + org.id)
|
|
);
|
|
const project = projects.items.filter((obj) => obj.name == projectName)[0];
|
|
const targets = JSON.parse(
|
|
execSync('boundary targets list -format json -scope-id ' + project.id)
|
|
);
|
|
const target = targets.items.filter((obj) => obj.name == targetName)[0];
|
|
|
|
connect = await connectToTarget(target.id);
|
|
await waitForSessionToBeVisible(page, targetName);
|
|
await page
|
|
.getByRole('cell', { name: targetName })
|
|
.locator('..')
|
|
.getByRole('button', { name: 'Cancel' })
|
|
.click();
|
|
} finally {
|
|
await deleteOrg(org.id);
|
|
// End `boundary connect` process
|
|
if (connect) {
|
|
connect.kill('SIGTERM');
|
|
}
|
|
}
|
|
});
|
|
|
|
test('Verify session created to target with address, then cancel the session', async ({
|
|
page,
|
|
}) => {
|
|
await page.goto('/');
|
|
let org;
|
|
let connect;
|
|
try {
|
|
const orgName = await createNewOrg(page);
|
|
const projectName = await createNewProject(page);
|
|
const targetName = await createNewTargetWithAddress(page);
|
|
|
|
await authenticateBoundaryCli();
|
|
const orgs = JSON.parse(execSync('boundary scopes list -format json'));
|
|
org = orgs.items.filter((obj) => obj.name == orgName)[0];
|
|
const projects = JSON.parse(
|
|
execSync('boundary scopes list -format json -scope-id ' + org.id)
|
|
);
|
|
const project = projects.items.filter((obj) => obj.name == projectName)[0];
|
|
const targets = JSON.parse(
|
|
execSync('boundary targets list -format json -scope-id ' + project.id)
|
|
);
|
|
const target = targets.items.filter((obj) => obj.name == targetName)[0];
|
|
|
|
connect = await connectToTarget(target.id);
|
|
await waitForSessionToBeVisible(page, targetName);
|
|
await page
|
|
.getByRole('cell', { name: targetName })
|
|
.locator('..')
|
|
.getByRole('button', { name: 'Cancel' })
|
|
.click();
|
|
} finally {
|
|
await deleteOrg(org.id);
|
|
// End `boundary connect` process
|
|
if (connect) {
|
|
connect.kill('SIGTERM');
|
|
}
|
|
}
|
|
});
|