react-code-dataset / wp-calypso /client /state /selectors /test /get-checkout-upgrade-intent.js
Devendra174's picture
Upload folder using huggingface_hub
1e92f2d verified
import getCheckoutUpgradeIntent from '../get-checkout-upgrade-intent';
describe( 'getCheckoutUpgradeIntent()', () => {
test( 'should return empty string when undefined', () => {
expect( getCheckoutUpgradeIntent( {} ) ).toBe( '' );
} );
test( 'should return value', () => {
expect(
getCheckoutUpgradeIntent( {
ui: {
checkout: {
upgradeIntent: 'phoenix feather',
},
},
} )
).toBe( 'phoenix feather' );
} );
} );