From 3b3f28217a880afd8ec6d45ff57ccd41784847b3 Mon Sep 17 00:00:00 2001 From: Sriram Viswanathan Date: Tue, 4 Apr 2017 18:35:50 -0300 Subject: [#938] Adds backup account step to test for missing translations with @anikarni --- web-ui/test/integration/translations.spec.js | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'web-ui') diff --git a/web-ui/test/integration/translations.spec.js b/web-ui/test/integration/translations.spec.js index 6faa7483..9b5256ee 100644 --- a/web-ui/test/integration/translations.spec.js +++ b/web-ui/test/integration/translations.spec.js @@ -9,25 +9,36 @@ import testI18n from './i18n'; describe('Translations', () => { context('Account Recovery Page', () => { - it('translates all keys on first step', () => { + it('translates all keys on admin recovery code step', () => { const app = mount(} />); expect(app.text()).toNotContain('untranslated', 'Unstranslated message found in the text: ' + app.text()); }); - it('translates all keys on second step', () => { + it('translates all keys on user recovery code step', () => { const app = mount(} />); app.find('form.admin-code').simulate('submit'); expect(app.text()).toNotContain('untranslated', 'Unstranslated message found in the text: ' + app.text()); }); - it('translates all keys on third step', () => { + it('translates all keys on new password step', () => { const app = mount(} />); app.find('form.admin-code').simulate('submit'); app.find('form.user-code').simulate('submit'); expect(app.text()).toNotContain('untranslated', 'Unstranslated message found in the text: ' + app.text()); }); + + it('translates all keys on backup account step', () => { + const app = mount(} />); + app.find('form.admin-code').simulate('submit'); + app.find('form.user-code').simulate('submit'); + app.find('input[name="new-password"]').simulate('change', {target: {value: '11'}}); + app.find('input[name="confirm-password"]').simulate('change', {target: {value: '11'}}); + app.find('form.new-password').simulate('submit'); + + expect(app.text()).toNotContain('untranslated', 'Unstranslated message found in the text: ' + app.text()); + }); }); context('Backup Account Page', () => { -- cgit v1.2.3