Change "Store Setup" link in top bar to "Finish setup" (https://github.com/woocommerce/woocommerce-admin/pull/6526)
This commit is contained in:
parent
a54c267d11
commit
4d1f1cdcb4
|
@ -122,7 +122,7 @@ export const ActivityPanel = ( { isEmbedded, query, userPreferencesData } ) => {
|
||||||
|
|
||||||
const setup = {
|
const setup = {
|
||||||
name: 'setup',
|
name: 'setup',
|
||||||
title: __( 'Store Setup', 'woocommerce-admin' ),
|
title: __( 'Finish setup', 'woocommerce-admin' ),
|
||||||
icon: <SetupProgress />,
|
icon: <SetupProgress />,
|
||||||
onClick: () => {
|
onClick: () => {
|
||||||
const currentLocation = window.location.href;
|
const currentLocation = window.location.href;
|
||||||
|
|
|
@ -144,7 +144,7 @@ describe( 'Activity Panel', () => {
|
||||||
expect( screen.getByText( '[DisplayOptions]' ) ).toBeDefined();
|
expect( screen.getByText( '[DisplayOptions]' ) ).toBeDefined();
|
||||||
} );
|
} );
|
||||||
|
|
||||||
it( 'should only render the store setup link when TaskList is not complete', () => {
|
it( 'should only render the finish setup link when TaskList is not complete', () => {
|
||||||
const { queryByText, rerender } = render(
|
const { queryByText, rerender } = render(
|
||||||
<ActivityPanel
|
<ActivityPanel
|
||||||
query={ {
|
query={ {
|
||||||
|
@ -153,7 +153,7 @@ describe( 'Activity Panel', () => {
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
expect( queryByText( 'Store Setup' ) ).toBeDefined();
|
expect( queryByText( 'Finish setup' ) ).toBeDefined();
|
||||||
|
|
||||||
useSelect.mockImplementation( () => ( {
|
useSelect.mockImplementation( () => ( {
|
||||||
requestingTaskListOptions: false,
|
requestingTaskListOptions: false,
|
||||||
|
@ -169,10 +169,10 @@ describe( 'Activity Panel', () => {
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
expect( queryByText( 'Store Setup' ) ).toBeNull();
|
expect( queryByText( 'Finish setup' ) ).toBeNull();
|
||||||
} );
|
} );
|
||||||
|
|
||||||
it( 'should not render the store setup link when on the home screen and TaskList is not complete', () => {
|
it( 'should not render the finish setup link when on the home screen and TaskList is not complete', () => {
|
||||||
const { queryByText } = render(
|
const { queryByText } = render(
|
||||||
<ActivityPanel
|
<ActivityPanel
|
||||||
query={ {
|
query={ {
|
||||||
|
@ -182,18 +182,18 @@ describe( 'Activity Panel', () => {
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
expect( queryByText( 'Store Setup' ) ).toBeNull();
|
expect( queryByText( 'Finish setup' ) ).toBeNull();
|
||||||
} );
|
} );
|
||||||
|
|
||||||
it( 'should render the store setup link when on embedded pages and TaskList is not complete', () => {
|
it( 'should render the finish setup link when on embedded pages and TaskList is not complete', () => {
|
||||||
const { getByText } = render(
|
const { getByText } = render(
|
||||||
<ActivityPanel isEmbedded query={ {} } />
|
<ActivityPanel isEmbedded query={ {} } />
|
||||||
);
|
);
|
||||||
|
|
||||||
expect( getByText( 'Store Setup' ) ).toBeInTheDocument();
|
expect( getByText( 'Finish setup' ) ).toBeInTheDocument();
|
||||||
} );
|
} );
|
||||||
|
|
||||||
it( 'should not render the store setup link when a user does not have capabilties', () => {
|
it( 'should not render the finish setup link when a user does not have capabilties', () => {
|
||||||
useUser.mockImplementation( () => ( {
|
useUser.mockImplementation( () => ( {
|
||||||
currentUserCan: () => false,
|
currentUserCan: () => false,
|
||||||
} ) );
|
} ) );
|
||||||
|
@ -206,7 +206,7 @@ describe( 'Activity Panel', () => {
|
||||||
/>
|
/>
|
||||||
);
|
);
|
||||||
|
|
||||||
expect( queryByText( 'Store Setup' ) ).toBeDefined();
|
expect( queryByText( 'Finish setup' ) ).toBeDefined();
|
||||||
} );
|
} );
|
||||||
|
|
||||||
describe( 'help panel tooltip', () => {
|
describe( 'help panel tooltip', () => {
|
||||||
|
|
Loading…
Reference in New Issue