File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/components/MessageInput/__tests__ Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -749,15 +749,17 @@ describe(`EditMessageForm`, () => {
749749 describe ( 'Uploads disabled' , ( ) => {
750750 const channelData = { channel : { own_capabilities : [ ] } } ;
751751
752- it ( 'should render file upload button disabled' , async ( ) => {
752+ it ( 'should not render file upload button if uploads are disabled' , async ( ) => {
753753 const { customChannel, customClient } = await setup ( {
754754 channelData,
755755 } ) ;
756756 const { container } = await renderComponent ( {
757757 customChannel,
758758 customClient,
759759 } ) ;
760- await waitFor ( ( ) => expect ( screen . getByTestId ( FILE_INPUT_TEST_ID ) ) . toBeDisabled ( ) ) ;
760+ await waitFor ( ( ) =>
761+ expect ( screen . queryByTestId ( FILE_INPUT_TEST_ID ) ) . not . toBeInTheDocument ( ) ,
762+ ) ;
761763 const results = await axe ( container ) ;
762764 expect ( results ) . toHaveNoViolations ( ) ;
763765 } ) ;
You can’t perform that action at this time.
0 commit comments