Skip to content
Open
Show file tree
Hide file tree
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
39 changes: 39 additions & 0 deletions e2e/project/tour.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
import { expect, test } from "../fixtures";
import { waitForLoadingOverlayGone } from "e2e/utils/waitForLoadingOverlayToDisappear";

test.describe("Tour Suite", () => {
test.beforeEach(async ({ page }) => {
await waitForLoadingOverlayGone(page);
await page.goto("/intro");
});

test("Onboarding tour - handle existing or create new", async ({ page }) => {
const startButton = page.getByRole("button", { name: "Start the tour Onboarding" });

await startButton.waitFor({ state: "attached" });
const isStartButtonVisible = await startButton.isVisible();

if (!isStartButtonVisible) {
await page.goto("/");
const deleteButton = page.getByRole("button", { name: "Delete project quickstart" });
await deleteButton.click();
await page
.getByRole("button", { name: "Delete", exact: true })
.or(page.getByRole("button", { name: "Ok" }))
.click();
await expect(deleteButton).toBeHidden();

await page.goto("/intro");
await expect(startButton).toBeVisible();
}

await startButton.click();
await page.getByRole("button", { name: "Go to the next step" }).click();
await page.getByRole("button", { name: "Deploy the project" }).click();
await page.getByRole("button", { name: "Manual Run" }).click();
await page.getByRole("button", { name: "View Sessions" }).click();
await page.getByRole("button", { name: "Refresh Data" }).click();

await expect(startButton).toBeHidden();
});
});
2 changes: 1 addition & 1 deletion src/components/molecules/toursProgressStepper.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export const ToursProgressStepper = ({ onStepStart, isStarting }: TutorialProgre
</div>
{completedTours?.includes(id) ? null : (
<Button
ariaLabel={t("startButton")}
ariaLabel={t("ariaLabel", { name })}
className="h-6 bg-green-800 px-4 py-3 font-semibold text-gray-1100 hover:bg-green-200"
disabled={isStarting[id] || completedTours?.includes(id)}
onClick={() => onStepStart(id)}
Expand Down
4 changes: 2 additions & 2 deletions src/components/organisms/dashboard/projectsTableRow.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -126,13 +126,13 @@ export const DashboardProjectsTableRow = ({
/>
</IconButton>
<IconButton
aria-label={t("buttons.deleteProject")}
ariaLabel={t("buttons.deleteProject", { name })}
className="group"
onClick={(event) => {
event.stopPropagation();
displayDeleteModal(status, deploymentId, id, name);
}}
title={t("buttons.deleteProject")}
title={t("buttons.deleteProject", { name })}
>
<IconSvg
className="stroke-white transition group-hover:stroke-green-200 group-active:stroke-green-800"
Expand Down
2 changes: 1 addition & 1 deletion src/locales/en/dashboard/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
},
"projects": {
"buttons": {
"deleteProject": "Delete project",
"deleteProject": "Delete project {{name}}",
"exportProject": "Export project",
"start": "Start",
"startNewProject": "Start New Project",
Expand Down
3 changes: 2 additions & 1 deletion src/locales/en/tour/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,8 @@
"description": "Learn how to create and run durable automation project with us",
"reviewButton": "Review",
"startButton": "Start",
"title": "Do Your Next Step"
"title": "Do Your Next Step",
"ariaLabel": "Start the tour {{name}}"
},
"general": {
"noLastStepUrl": "Couldn't re-initiate the tour"
Expand Down