Skip to content

Commit

Permalink
Add tests for unattached domain manage button
Browse files Browse the repository at this point in the history
  • Loading branch information
Imran92 committed Dec 26, 2024
1 parent 80769d7 commit b1a913e
Showing 1 changed file with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,21 @@ describe( 'DomainOverviewPane', () => {
expect( screen.getByText( 'Manage site' ) ).toBeInTheDocument();
} );

it( 'does not show Manage Site button when domain only and unattached', () => {
const siteProps = {
...defaultProps,
site: {
...defaultProps.site,
options: {
...defaultProps.site.options,
is_domain_only: true,
},
},
};
renderComponent( siteProps );
expect( screen.queryByText( 'Manage site' ) ).not.toBeInTheDocument();
} );

it( 'handles tab switching', () => {
renderComponent();
fireEvent.click( screen.getByText( 'Email' ) );
Expand Down

0 comments on commit b1a913e

Please sign in to comment.