Skip to content

Commit

Permalink
ESLint: Fix jest-dom/prefer-to-have-class rule violations (#44902)
Browse files Browse the repository at this point in the history
  • Loading branch information
tyxla authored Oct 13, 2022
1 parent d7e9b29 commit a3ec098
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions packages/components/src/date-time/time/test/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -303,12 +303,8 @@ describe( 'TimePicker', () => {
* This is not ideal, but best of we can do for now until we refactor
* AM/PM into accessible elements, like radio buttons.
*/
expect(
screen.getByText( 'AM' ).classList.contains( 'is-primary' )
).toBe( false );
expect(
screen.getByText( 'PM' ).classList.contains( 'is-primary' )
).toBe( true );
expect( screen.getByText( 'AM' ) ).not.toHaveClass( 'is-primary' );
expect( screen.getByText( 'PM' ) ).toHaveClass( 'is-primary' );
} );

it( 'should have different layouts/orders for 12/24 hour formats', () => {
Expand Down

0 comments on commit a3ec098

Please sign in to comment.