Skip to content

Commit 46acdad

Browse files
committed
test: fix wizard test case
1 parent b7dbd34 commit 46acdad

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

test/wizard.test.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const ComponentWithHeader = (
1818
);
1919

2020
const ComponentWithFooter = (
21-
<Wizard header={<p>header</p>}>
21+
<Wizard footer={<p>footer</p>}>
2222
<p>step 1</p>
2323
<p>step 2</p>
2424
</Wizard>
@@ -37,7 +37,7 @@ describe('Wizard', () => {
3737
expect(queryByText('step 2')).not.toBeInTheDocument();
3838
});
3939

40-
test('should render second step with passed `startIndex`', () => {
40+
test('should render second step with `startIndex`', () => {
4141
const { queryByText } = render(
4242
<Wizard startIndex={1}>
4343
<p>step 1</p>
@@ -46,6 +46,7 @@ describe('Wizard', () => {
4646
);
4747

4848
expect(queryByText('step 2')).toBeInTheDocument();
49+
expect(queryByText('step 1')).not.toBeInTheDocument();
4950
});
5051

5152
test('should render header', () => {
@@ -57,6 +58,6 @@ describe('Wizard', () => {
5758
test('should render footer', () => {
5859
const { queryByText } = render(ComponentWithFooter);
5960

60-
expect(queryByText('header')).toBeInTheDocument();
61+
expect(queryByText('footer')).toBeInTheDocument();
6162
});
6263
});

0 commit comments

Comments
 (0)