1 | import React from "react";
|
2 |
|
3 | import { render, screen } from "@/test/render";
|
4 |
|
5 | import { FixedWeeks } from "./Fixedweeks";
|
6 |
|
7 | const today = new Date(2021, 10, 25);
|
8 |
|
9 | beforeAll(() => jest.setSystemTime(today));
|
10 | afterAll(() => jest.useRealTimers());
|
11 |
|
12 | beforeEach(() => {
|
13 | render(<FixedWeeks />);
|
14 | });
|
15 |
|
16 | test("should render 7 rows", () => {
|
17 | expect(screen.getAllByRole("row")).toHaveLength(7);
|
18 | });
|