-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat : convert profileurl to pass as prop
- Loading branch information
1 parent
33f2e36
commit b30d052
Showing
6 changed files
with
140 additions
and
72 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,19 @@ | ||
import { beforeEach, describe, expect, it } from "vitest"; | ||
import { render, screen } from "@testing-library/react"; | ||
import Progress from "./Progress"; // Adjust the import path as needed | ||
import { render, screen, waitFor } from "@testing-library/react"; | ||
import Progress from "./Progress"; | ||
import { mock } from "vitest-mock-extended"; | ||
import useMembers from "../../hooks/useMembers"; | ||
import { test, vi } from "vitest"; | ||
|
||
describe("<Progress/>", () => { | ||
beforeEach(() => render(<Progress />)); | ||
vi.mock("../../hooks/useMembers"); | ||
|
||
it("renders the table", () => { | ||
const table = screen.getByRole("table"); | ||
expect(table).toBeInTheDocument(); | ||
}); | ||
test("render the site header", () => { | ||
vi.mocked(useMembers).mockReturnValue( | ||
mock({ isLoading: false, error: null, members: [] }), | ||
); | ||
|
||
it("renders the page header", () => { | ||
const header = screen.getByRole("banner"); | ||
expect(header).toBeInTheDocument(); | ||
}); | ||
render(<Progress />); | ||
|
||
it("renders the title", () => { | ||
const heading = screen.getByRole("heading", { level: 1 }); | ||
expect(heading).toHaveTextContent("풀이 현황"); | ||
}); | ||
|
||
it("renders footer", () => { | ||
expect(screen.getByRole("contentinfo")); | ||
}); | ||
const header = screen.getByRole("banner"); | ||
expect(header).toBeInTheDocument(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters