Skip to content

Commit

Permalink
Add test to confirm migraiton flow
Browse files Browse the repository at this point in the history
  • Loading branch information
lsl committed Oct 17, 2023
1 parent 8f291e9 commit 1f67936
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions client/lib/login/test/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -183,4 +183,18 @@ describe( 'getSignupUrl', () => {
getSignupUrl( { redirect_to: 'https://example.com' }, '/log-in/jetpack', null, 'en', '' )
).toEqual( '/jetpack/connect' );
} );

test( 'redirect_to=public.api/connect/?action=verify uses /start/account with ?redirect_to passthrough', () => {
expect(
getSignupUrl(
{ redirect_to: 'https://public-api.wordpress.com/public.api/connect/?action=verify' },
'/log-in',
null,
'en',
''
)
).toEqual(
'/start/account?redirect_to=https%3A%2F%2Fpublic-api.wordpress.com%2Fpublic.api%2Fconnect%2F%3Faction%3Dverify'
);
} );
} );

0 comments on commit 1f67936

Please sign in to comment.