Skip to content

Commit

Permalink
debuggin e2e tests --still
Browse files Browse the repository at this point in the history
  • Loading branch information
wkelly17 committed Dec 6, 2023
1 parent e526fc5 commit 819fc13
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions tests/dot.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,15 +38,19 @@ test("No horizontal scroll", async ({page}) => {
test.only("New Testament renders 27 books", async ({page}) => {
await page.goto("/benin");
const playlistListing = page.getByTestId("booksAvailable");
await playlistListing.waitFor();
await playlistListing.waitFor({
state: "attached",
});
const books = playlistListing.locator("li");
await expect(books).toHaveCount(27);
});
test("Matthew Renders 28 chapter buttons", async ({page}) => {
await page.goto("/benin");

const playlistListing = page.getByTestId("chapterSelector");
await playlistListing.waitFor();
await playlistListing.waitFor({
state: "attached",
});
const chapters = playlistListing.locator("li");

await expect(chapters).toHaveCount(28);
Expand All @@ -55,7 +59,9 @@ test("state data attributes for chapter / vid are correct", async ({page}) => {
await page.goto("/benin");

const stateChecker = page.getByTestId("stateChecker");
await stateChecker.waitFor();
await stateChecker.waitFor({
state: "attached",
});
const dataCurBook = await stateChecker.getAttribute("data-currentbook");
const isMatthew = dataCurBook === "MAT";
const dataCur = await stateChecker.getAttribute("data-currentchap");
Expand Down

0 comments on commit 819fc13

Please sign in to comment.