Skip to content

Commit

Permalink
Update unit test to account for removed Composing card
Browse files Browse the repository at this point in the history
  • Loading branch information
kraftbj committed Sep 30, 2019
1 parent 9e476f3 commit e534729
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions _inc/client/components/settings-card/test/component.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,6 @@ describe( 'SettingsCard', () => {
'photon'
],
allCardsForNonAdmin = [
'composing',
'post-by-email'
];

Expand Down Expand Up @@ -172,13 +171,13 @@ describe( 'SettingsCard', () => {
userCanManageModules: false
} );

it( 'does not render cards that are not Composing or Post by Email', () => {
it( 'does not render cards that are not Post by Email', () => {
allCardsNonAdminCantAccess.forEach( item => {
expect( shallow( <SettingsCard { ...testProps } module={ item } ><p>Child</p></SettingsCard> ).find( 'form' ) ).to.have.length( 0 );
} );
} );

it( 'renders Composing and Post by Email cards', () => {
it( 'renders Post by Email cards', () => {
allCardsForNonAdmin.forEach( item => {
expect( shallow( <SettingsCard { ...testProps } module={ item } ><p>Child</p></SettingsCard> ).find( 'form' ) ).to.have.length( 1 );
} );
Expand Down

0 comments on commit e534729

Please sign in to comment.