test(onboarding): add ProgressSidebar test for currentStep=3 (all prior steps completed)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -53,4 +53,11 @@ describe('ProgressSidebar', () => {
|
|||||||
expect(screen.getByTestId('step-2')).not.toHaveAttribute('aria-current');
|
expect(screen.getByTestId('step-2')).not.toHaveAttribute('aria-current');
|
||||||
expect(screen.getByTestId('step-3')).not.toHaveAttribute('aria-current');
|
expect(screen.getByTestId('step-3')).not.toHaveAttribute('aria-current');
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('step 3 active: steps 1 and 2 are both completed', () => {
|
||||||
|
render(ProgressSidebar, { props: { currentStep: 3 } });
|
||||||
|
expect(screen.getByTestId('step-1')).toHaveAttribute('data-state', 'completed');
|
||||||
|
expect(screen.getByTestId('step-2')).toHaveAttribute('data-state', 'completed');
|
||||||
|
expect(screen.getByTestId('step-3')).toHaveAttribute('aria-current', 'step');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user