@@ -296,7 +296,7 @@ describe('StaffExpenseReport', () => {
296296 expect ( getByRole ( 'button' , { name : 'Next Month' } ) ) . toBeInTheDocument ( ) ;
297297 } , 10000 ) ;
298298
299- it ( 'shows filter date range title and hides month navigation when date filters are applied' , async ( ) => {
299+ it ( 'hides month navigation when date filters are applied' , async ( ) => {
300300 Settings . now = ( ) => new Date ( 2020 , 0 , 20 ) . valueOf ( ) ;
301301
302302 const { getByRole, findByRole, getByLabelText, queryByRole } = render (
@@ -309,17 +309,7 @@ describe('StaffExpenseReport', () => {
309309 userEvent . click ( getByLabelText ( 'Select Date Range' ) ) ;
310310 userEvent . click ( getByRole ( 'option' , { name : 'Month to Date' } ) ) ;
311311
312- await waitFor ( ( ) =>
313- expect ( getByRole ( 'button' , { name : 'Apply Filters' } ) ) . not . toBeDisabled ( ) ,
314- ) ;
315- userEvent . click ( getByRole ( 'button' , { name : 'Apply Filters' } ) ) ;
316-
317- expect (
318- await findByRole ( 'heading' , {
319- level : 6 ,
320- name : 'January 1, 2020 - January 20, 2020' ,
321- } ) ,
322- ) . toBeInTheDocument ( ) ;
312+ userEvent . click ( await findByRole ( 'button' , { name : 'Apply Filters' } ) ) ;
323313
324314 expect (
325315 queryByRole ( 'button' , { name : 'Previous Month' } ) ,
0 commit comments