Skip to content

Commit 6c5d1e3

Browse files
committed
[LEMS-3361/use-wb-tab-in-expression] undo changes in test since changes related to popover dismiss was removed
1 parent c90dfb4 commit 6c5d1e3

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

packages/math-input/src/components/keypad/__tests__/keypad.test.tsx

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,40 @@ describe("keypad", () => {
9999
expect(container).toMatchSnapshot("first render");
100100
});
101101

102+
it(`shows optional dismiss button`, async () => {
103+
// Arrange
104+
// Act
105+
render(
106+
<Keypad
107+
onClickKey={() => {}}
108+
onAnalyticsEvent={async () => {}}
109+
showDismiss
110+
/>,
111+
);
112+
113+
// Assert
114+
expect(
115+
screen.getByRole("button", {
116+
name: "Dismiss",
117+
}),
118+
).toBeInTheDocument();
119+
});
120+
121+
it(`hides optional dismiss button`, () => {
122+
// Arrange
123+
// Act
124+
render(
125+
<Keypad onClickKey={() => {}} onAnalyticsEvent={async () => {}} />,
126+
);
127+
128+
// Assert
129+
expect(
130+
screen.queryByRole("button", {
131+
name: "Dismiss",
132+
}),
133+
).not.toBeInTheDocument();
134+
});
135+
102136
it(`shows the dot symbol when convertDotToTimes is false`, async () => {
103137
// Arrange
104138
// Act

0 commit comments

Comments
 (0)