File tree Expand file tree Collapse file tree 1 file changed +0
-28
lines changed Expand file tree Collapse file tree 1 file changed +0
-28
lines changed Original file line number Diff line number Diff line change @@ -141,7 +141,6 @@ describe(SpecialButton, () => {
141141 // Initial state: pending
142142 expect ( screen . getByText ( "Click Me" ) ) . toBeInTheDocument ( ) ;
143143 expect ( button ) . not . toBeDisabled ( ) ;
144- expect ( button ) . toHaveClass ( "special-button" , "pending" ) ;
145144
146145 // Rerender with loading state
147146 rerender (
@@ -154,33 +153,6 @@ describe(SpecialButton, () => {
154153 button = screen . getByRole ( "button" ) ;
155154 expect ( screen . getByText ( "Loading..." ) ) . toBeInTheDocument ( ) ;
156155 expect ( button ) . toBeDisabled ( ) ;
157- expect ( button ) . toHaveClass ( "special-button" , "loading" ) ;
158-
159- // Rerender with success state
160- rerender (
161- < SpecialButton
162- onClick = { mockOnClick }
163- state = "success"
164- />
165- ) ;
166-
167- button = screen . getByRole ( "button" ) ;
168- expect ( screen . getByText ( "Success!" ) ) . toBeInTheDocument ( ) ;
169- expect ( button ) . not . toBeDisabled ( ) ;
170- expect ( button ) . toHaveClass ( "special-button" , "success" ) ;
171-
172- // Rerender with error state
173- rerender (
174- < SpecialButton
175- onClick = { mockOnClick }
176- state = "error"
177- />
178- ) ;
179-
180- button = screen . getByRole ( "button" ) ;
181- expect ( screen . getByText ( "Error!" ) ) . toBeInTheDocument ( ) ;
182- expect ( button ) . not . toBeDisabled ( ) ;
183- expect ( button ) . toHaveClass ( "special-button" , "error" ) ;
184156 } ) ;
185157
186158
You can’t perform that action at this time.
0 commit comments