99 buildCancelledJobProposal ,
1010 buildRejectedJobProposal ,
1111 buildDeletedJobProposal ,
12+ buildRevokedJobProposal ,
1213} from 'support/factories/gql/fetchFeedsManagersWithProposals'
1314import { JobProposalsCard } from './JobProposalsCard'
1415
@@ -33,6 +34,7 @@ describe('JobProposalsCard', () => {
3334 buildCancelledJobProposal ( { pendingUpdate : true } ) ,
3435 buildDeletedJobProposal ( { pendingUpdate : true } ) ,
3536 buildDeletedJobProposal ( { pendingUpdate : false } ) ,
37+ buildRevokedJobProposal ( { pendingUpdate : false } ) ,
3638 ]
3739
3840 renderWithRouter ( < JobProposalsCard proposals = { proposals } /> )
@@ -92,4 +94,15 @@ describe('JobProposalsCard', () => {
9294 const rows = await findAllByRole ( 'row' )
9395 expect ( rows ) . toHaveLength ( 2 )
9496 } )
97+
98+ it ( 'renders the revoked job proposals' , async ( ) => {
99+ const proposals = buildJobProposals ( )
100+
101+ renderWithRouter ( < JobProposalsCard proposals = { proposals } /> )
102+
103+ userEvent . click ( getByRole ( 'tab' , { name : / r e v o k e d / i } ) )
104+
105+ const rows = await findAllByRole ( 'row' )
106+ expect ( rows ) . toHaveLength ( 2 )
107+ } )
95108} )
0 commit comments