mirror of
https://github.com/gradio-app/gradio.git
synced 2025-01-30 11:00:11 +08:00
1419538ea7
* asd * changes * fix everything * cleanup * add changeset * fix casing * lockfile * fix casing * fix ci, enable linting * fix test * add changeset * add changeset * delete changeset * fix dirs * fix casing * fix notebooks * fix casing * fix casing * fix casing * fix casing * fix casing * fix casing * fix casing * fix casing --------- Co-authored-by: gradio-pr-bot <gradio-pr-bot@users.noreply.github.com>
26 lines
560 B
TypeScript
26 lines
560 B
TypeScript
import { test, describe, assert, afterEach, vi } from "vitest";
|
|
import { cleanup, render } from "@gradio/tootils";
|
|
|
|
import Group from "./static";
|
|
|
|
describe("Group", () => {
|
|
afterEach(() => {
|
|
cleanup();
|
|
});
|
|
|
|
test("setting visible to false hides the Group", async () => {
|
|
render(Group, {
|
|
elem_id: "group",
|
|
visible: false
|
|
});
|
|
|
|
const groupElement = document.getElementById("group");
|
|
|
|
assert(groupElement !== null, "Group element not found.");
|
|
assert(
|
|
groupElement.classList.contains("hide"),
|
|
"Group element is not hidden."
|
|
);
|
|
});
|
|
});
|