This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export const NotificationTypes = { | |
| invitation: [SendMethod.email, SendMethod.push], | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const SendMethod = { | |
| SMS: 'SMS', | |
| email: 'email', | |
| push: 'push', | |
| buildin: 'buildin', | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const i18n = { | |
| __(key, { _locale, ...context }) { | |
| // ... localize string here | |
| console.log('localize', key, 'for', _locale, 'with', context); | |
| }, | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const localizedStrings = { | |
| en: { | |
| 'notifications.invitation.email': 'Wellcome to our system. Click this {$link} to accept invitation. It will expire after {$expirationDate}', | |
| 'notifications.invitation.push': 'Invitation was sent to your email address', | |
| }, | |
| // ... other languages | |
| fr: { | |
| // ... | |
| }, | |
| }; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe('Status payment', () => { | |
| it('transaction status should be "PAYMENT OPENED"', () => { | |
| browser.waitForExist('.transaction_status'); | |
| const status = browser.getText('.transaction_status'); | |
| assert.equal(status, 'PAYMENT OPENED'); | |
| }); | |
| it('should be status spinner', () => { | |
| assert.isTrue(browser.isExisting('.payment_status_loading')); | |
| }); | |
| it('transaction status should be "PAYMENT SUCCESS" after 5 sec', () => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe('Payment service page', () => { | |
| it('should be redirected to "Payment status" page after submit Payment service form', () => { | |
| common.click('input[value="paid"]'); | |
| common.click('.confirm-payment'); | |
| browser.waitForExist('.payment_status .card--confirm'); | |
| assert.match(browser.getUrl(), /success/); | |
| }); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe('Confirm payment page', () => { | |
| const testUserAddress = { | |
| givenName: 'John', | |
| familyName: 'Smith', | |
| countryName: 'NL', | |
| city: 'Amsterdam', | |
| street1: 'John M. Keynesplein', | |
| street2: '12-45', | |
| state: 'Noord-Holland', | |
| zip: '1066 EP', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe('Payment methods page', () => { | |
| it('"Credit Card" payment method should be active', () => { | |
| browser.waitForExist('li.creditcard'); | |
| }); | |
| it('Redirect to "Credit card payment" page after click on "Pay with Credit Card" button', () => { | |
| common.click('li.creditcard'); | |
| browser.waitForExist('.payment-confirm'); | |
| const currentUrl = browser.getUrl(); | |
| assert.match(currentUrl, /payment/); | |
| assert.match(currentUrl, /creditcard/); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| describe('Event booking page', () => { | |
| /*...*/ | |
| it('should be error when do not agree with terms', () => { | |
| common.click('.book-button'); | |
| browser.waitForExist('.terms-error'); | |
| assert.equal(browser.getText('.terms-error'), 'Please agree with our terms to continue'); | |
| common.click(selector['Booking terms checkbox']); | |
| }); | |
| }); |