Skip to content

Commit

Permalink
fix menu test
Browse files Browse the repository at this point in the history
  • Loading branch information
macfarlandian committed Mar 10, 2021
1 parent 5d4f33f commit bdd93db
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion spotlight-client/src/SiteNavigation/SiteNavigation.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ describe("on small screens", () => {
const menu = screen.getByTestId("NavMenu");
const navLinks = await within(menu).findAllByRole("link");

expect(navLinks.length).toBe(5);
expect(navLinks.length).toBe(6);

expect(navLinks[0]).toHaveTextContent("Home");
expect(navLinks[0]).toHaveAttribute("href", "/us-nd");
Expand All @@ -124,6 +124,12 @@ describe("on small screens", () => {

expect(navLinks[4]).toHaveTextContent("Parole");
expect(navLinks[4]).toHaveAttribute("href", "/us-nd/collections/parole");

expect(navLinks[5]).toHaveTextContent("Racial Disparities");
expect(navLinks[5]).toHaveAttribute(
"href",
"/us-nd/collections/racial-disparities"
);
});

test("menu closes after navigation", async () => {
Expand Down

0 comments on commit bdd93db

Please sign in to comment.