Radish alpha
r
Radicle web interface
Radicle
Git (anonymous pull)
Log in to clone via SSH
Add moved and copied files e2e tests
Sebastian Martinez committed 2 years ago
commit fb06b5fe8b24f70d65b987afbaf0a7e8352a0357
parent 1b01216bf812b9a892f4b1bf4dfc2dda5001b1f9
1 file changed +12 -2
modified tests/e2e/project/commit.spec.ts
@@ -87,11 +87,21 @@ test("moved file", async ({ page }) => {
    page.locator("header").filter({ hasText: "moves/111.txt → moves/222.txt" }),
  ).toBeVisible();

-
  // TODO: Add assertions for diff.
+
  await expect(page.getByText("moved", { exact: true })).toBeVisible();
  await expect(page.getByText("333")).toBeVisible();
});

-
// TODO: Add copy operation detection spec.
+
test("copied file", async ({ page }) => {
+
  await page.goto(
+
    `${sourceBrowsingUrl}/remotes/${aliceRemote}/commits/f48a1056a5bd02277978f6e8a00517a967546340`,
+
  );
+
  await expect(
+
    page
+
      .locator("header")
+
      .filter({ hasText: "copies/aaa.txt → copies/aaa_copy.txt" }),
+
  ).toBeVisible();
+
  await expect(page.getByText("copied", { exact: true })).toBeVisible();
+
});

test("navigation to source tree at specific revision", async ({ page }) => {
  await page.goto(