Radish alpha
r
rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5
Radicle web interface
Radicle
Git
Make specs less flaky
Rūdolfs Ošiņš committed 2 months ago
commit dd243612b80c9552a3806094316ec3a665db44d5
parent 5c12ab3
4 files changed +7 -0
modified tests/e2e/repo.spec.ts
@@ -64,6 +64,7 @@ test("repo description", async ({ page, peer }) => {
    description: "Radicle Heartwood Protocol & Stack",
  });
  await page.goto(peer.ridUrl(rid));
+
  await page.waitForLoadState("networkidle");
  await expect(
    page.getByText("Radicle Heartwood Protocol & Stack"),
  ).toBeVisible();
modified tests/e2e/repo/commits.spec.ts
@@ -131,6 +131,7 @@ test("commit messages with double colon not converted into single colon", async

test("expand commit message", async ({ page }) => {
  await page.goto(sourceBrowsingUrl);
+
  await page.waitForLoadState("networkidle");
  await page
    .getByRole("link", { name: `Commits ${aliceMainCommitCount}` })
    .click();
modified tests/e2e/repo/issues.spec.ts
@@ -3,6 +3,7 @@ import { createRepo } from "@tests/support/repo";

test("navigate issue listing", async ({ page }) => {
  await page.goto(cobUrl);
+
  await page.waitForLoadState("networkidle");
  await page.getByRole("link", { name: "Issues 1" }).click();
  await expect(page).toHaveURL(`${cobUrl}/issues`);

modified tests/e2e/repo/patch.spec.ts
@@ -7,6 +7,7 @@ test("navigate patch details", async ({ page }) => {
  await page.getByRole("link", { name: "Add subtitle to README" }).click();
  await expect(page).toHaveURL(/commits\/[a-f0-9]{40}$/);
  await page.goBack();
+
  await page.waitForLoadState("networkidle");
  await page.getByRole("link", { name: "Changes" }).click();
  await expect(page).toHaveURL(/patches\/[a-f0-9]{40}\?tab=changes$/);
});
@@ -77,6 +78,7 @@ test("navigate through revision diffs", async ({ page }) => {
      /patches\/[a-f0-9]{40}\?diff=38c225e2a0b47ba59def211f4e4825c31d9463ec\.\.9e4feab1b2123dfa5f22bd0e4656060ec9296638$/,
    );
    await page.goBack();
+
    await page.waitForLoadState("networkidle");
    await secondRevision
      .getByRole("button", { name: "toggle-context-menu" })
      .first()
@@ -94,6 +96,7 @@ test("navigate through revision diffs", async ({ page }) => {
      /patches\/[a-f0-9]{40}\?diff=88b7fd90389c1a629f91ed7bf838d4b947426622\.\.9e4feab1b2123dfa5f22bd0e4656060ec9296638$/,
    );
    await page.goBack();
+
    await page.waitForLoadState("networkidle");
  }
  // First revision and DiffStatBadge shortcut.
  {
@@ -141,6 +144,7 @@ test("commit listing ordering keeping stable on browser navigation", async ({
  await expectCorrectCommitListing();
  await page.getByRole("link", { name: "Rewrite subtitle to README" }).click();
  await page.goBack();
+
  await page.waitForLoadState("networkidle");
  await page
    .getByRole("heading", { name: "Taking another stab at the README" })
    .waitFor();