import * as React from "react";
import { View } from "react-native";
import { render } from "@testing-library/react-native";
import { CollapsibleTextContainer } from "../CollapsibleTextContainer";
describe("CollapsibleTextContainer", () => {
it("render container+children when label is presented", () => {
const { toJSON } = render(
);
const result = toJSON();
expect(result).not.toBeNull();
expect(toJSON()).toMatchSnapshot();
});
it("render nothing when label is empty", () => {
const { toJSON } = render(
);
const result = toJSON();
expect(result).toBeNull();
});
it("render nothing when label is not passed", () => {
const { toJSON } = render(
);
const result = toJSON();
expect(result).toBeNull();
});
it("render nothing when label is undefined", () => {
const { toJSON } = render(
);
const result = toJSON();
expect(result).toBeNull();
});
});