Add moved and copied files e2e tests

Signed-off-by: Sebastian Martinez <me@sebastinez.dev>
This commit is contained in:
Sebastian Martinez
2023-09-19 07:50:27 +02:00
committed by Rūdolfs Ošiņš
parent 1b01216bf8
commit fb06b5fe8b
+12 -2
View File
@@ -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(