diff --git a/tests/e2e/clipboard.spec.ts b/tests/e2e/clipboard.spec.ts index 3828bec..ad295b2 100644 --- a/tests/e2e/clipboard.spec.ts +++ b/tests/e2e/clipboard.spec.ts @@ -1,6 +1,7 @@ import { chromium } from "playwright"; import { expect, markdownRid, test } from "@tests/support/fixtures.js"; +import { formatRepositoryId } from "@app/lib/utils"; // We explicitly run all clipboard tests withing the context of a single test // so that we don't run into race conditions, because there is no way to isolate @@ -18,7 +19,7 @@ test("copy to clipboard", async () => { // Repo ID. { - await page.getByLabel("repo-id").first().click(); + await page.getByText(formatRepositoryId(markdownRid)).click(); const clipboardContent = await page.evaluate( "navigator.clipboard.readText()", );