Skip to content

Commit

Permalink
Update FlexgridItem.test.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
aversini committed Nov 25, 2023
1 parent 1cc8632 commit db15930
Showing 1 changed file with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,20 @@ describe("FlexgridItem (exceptions)", () => {
it("should be able to require/import from root", () => {
expect(FlexgridItem).toBeDefined();
});

it("should render default content even without a Flexgrid parent", () => {
const { getByTestId } = render(
<FlexgridItem data-testid="gridcell-1">
<Button>item 1</Button>
</FlexgridItem>,
);
const gridCellRoot = getByTestId("gridcell-1");
expect(gridCellRoot).toHaveTextContent("item 1");
expectToHaveStyles(gridCellRoot, {
"padding-left": "0rem",
"padding-top": "0rem",
});
});
});

describe("FlexgridItem default rules", () => {
Expand Down

0 comments on commit db15930

Please sign in to comment.