-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
78e8c01
commit 2e08567
Showing
32 changed files
with
1,204 additions
and
22 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,7 @@ | ||
import "@testing-library/jest-dom"; | ||
|
||
global.ResizeObserver = jest.fn(() => ({ | ||
observe: jest.fn(), | ||
disconnect: jest.fn(), | ||
unobserve: jest.fn(), | ||
})); |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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,5 +1,11 @@ | ||
import { ContrastResults } from "@/components/contrast-results"; | ||
import { ColorInputs } from "@/components/color-inputs"; | ||
|
||
export default function Home() { | ||
return <ContrastResults />; | ||
return ( | ||
<> | ||
<ContrastResults /> | ||
<ColorInputs /> | ||
</> | ||
); | ||
} |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import { describe, it } from "@jest/globals"; | ||
import { render } from "@testing-library/react"; | ||
|
||
import { Panel } from "../panel"; | ||
|
||
describe("Color Panel", () => { | ||
it("Correct rendering and unmount", () => { | ||
const screen = render(<Panel label="Background" />); | ||
|
||
expect(() => screen.unmount()).not.toThrow(); | ||
}); | ||
|
||
it("Should show label and children properties", () => { | ||
const screen = render(<Panel label="Background">Content</Panel>); | ||
|
||
expect(screen.getByText("Content")).toBeInTheDocument(); | ||
expect(screen.getByText("Background")).toBeInTheDocument(); | ||
}); | ||
}); |
Oops, something went wrong.