chore: rename 'Deployment' button to 'Administration' (#14240)

* chore: rename 'Deployment' button to 'Administration' 

Reword "Auditing" to a noun like the rest of the dropdowns
This commit is contained in:
Steven Masley
2024-08-13 11:21:02 -05:00
committed by GitHub
parent f1feb40e17
commit ccc664de37
5 changed files with 17 additions and 11 deletions
@@ -52,7 +52,7 @@ export const DeploymentDropdown: FC<DeploymentDropdownProps> = ({
/>
}
>
Deployment
Administration
</Button>
</PopoverTrigger>
@@ -128,7 +128,7 @@ const DeploymentDropdownContent: FC<DeploymentDropdownProps> = ({
css={styles.menuItem}
onClick={onPopoverClose}
>
Auditing
Audit Logs
</MenuItem>
)}
{canViewHealth && (
@@ -22,7 +22,7 @@ describe("Navbar", () => {
}),
);
render(<App />);
const deploymentMenu = await screen.findByText("Deployment");
const deploymentMenu = await screen.findByText("Administration");
await userEvent.click(deploymentMenu);
await waitFor(
() => {
@@ -37,7 +37,7 @@ describe("Navbar", () => {
// by default, user is an Admin with permission to see the audit log,
// but is unlicensed so not entitled to see the audit log
render(<App />);
const deploymentMenu = await screen.findByText("Deployment");
const deploymentMenu = await screen.findByText("Administration");
await userEvent.click(deploymentMenu);
await waitFor(
() => {
@@ -26,7 +26,9 @@ type Story = StoryObj<typeof NavbarView>;
export const ForAdmin: Story = {
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
await userEvent.click(canvas.getByRole("button", { name: "Deployment" }));
await userEvent.click(
canvas.getByRole("button", { name: "Administration" }),
);
},
};
@@ -41,7 +43,9 @@ export const ForAuditor: Story = {
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
await userEvent.click(canvas.getByRole("button", { name: "Deployment" }));
await userEvent.click(
canvas.getByRole("button", { name: "Administration" }),
);
},
};
@@ -56,7 +60,9 @@ export const ForOrgAdmin: Story = {
},
play: async ({ canvasElement }) => {
const canvas = within(canvasElement);
await userEvent.click(canvas.getByRole("button", { name: "Deployment" }));
await userEvent.click(
canvas.getByRole("button", { name: "Administration" }),
);
},
};
@@ -69,7 +69,7 @@ describe("NavbarView", () => {
canViewAuditLog
/>,
);
const deploymentMenu = await screen.findByText("Deployment");
const deploymentMenu = await screen.findByText("Administration");
await userEvent.click(deploymentMenu);
const userLink = await screen.findByText(navLanguage.users);
expect((userLink as HTMLAnchorElement).href).toContain("/users");
@@ -88,7 +88,7 @@ describe("NavbarView", () => {
canViewAuditLog
/>,
);
const deploymentMenu = await screen.findByText("Deployment");
const deploymentMenu = await screen.findByText("Administration");
await userEvent.click(deploymentMenu);
const auditLink = await screen.findByText(navLanguage.audit);
expect((auditLink as HTMLAnchorElement).href).toContain("/audit");
@@ -107,7 +107,7 @@ describe("NavbarView", () => {
canViewAuditLog
/>,
);
const deploymentMenu = await screen.findByText("Deployment");
const deploymentMenu = await screen.findByText("Administration");
await userEvent.click(deploymentMenu);
const deploymentSettingsLink = await screen.findByText(
navLanguage.deployment,
@@ -31,7 +31,7 @@ export const Language = {
workspaces: "Workspaces",
templates: "Templates",
users: "Users",
audit: "Auditing",
audit: "Audit Logs",
deployment: "Settings",
};