diff options
author | Anike Arni <aarni@thoughtworks.com> | 2017-02-08 16:05:44 -0200 |
---|---|---|
committer | Anike Arni <aarni@thoughtworks.com> | 2017-02-08 17:46:43 -0200 |
commit | ad7ad7c7f781706b25b29c80c642006a4d18411a (patch) | |
tree | bd634c07b72080b91ea0507827cf04c4f3a73553 /web-ui/test | |
parent | 0d4cf4ad3a5da62f65730d6c3e3665fc12d72590 (diff) |
[#922] Create footer
with @tayanefernandes
Diffstat (limited to 'web-ui/test')
-rw-r--r-- | web-ui/test/unit/account_recovery/page.spec.js | 5 | ||||
-rw-r--r-- | web-ui/test/unit/common/footer/footer.spec.js | 17 |
2 files changed, 19 insertions, 3 deletions
diff --git a/web-ui/test/unit/account_recovery/page.spec.js b/web-ui/test/unit/account_recovery/page.spec.js index 6a139167..6046c5d5 100644 --- a/web-ui/test/unit/account_recovery/page.spec.js +++ b/web-ui/test/unit/account_recovery/page.spec.js @@ -4,12 +4,11 @@ import React from 'react'; import { Page } from 'src/account_recovery/page'; describe('Page', () => { - let mockT; let page; beforeEach(() => { - mockT = key => key; - page = shallow(<Page t={mockT} />); + const mockTranslations = key => key; + page = shallow(<Page t={mockTranslations} />); }); it('renders backup email page title', () => { diff --git a/web-ui/test/unit/common/footer/footer.spec.js b/web-ui/test/unit/common/footer/footer.spec.js new file mode 100644 index 00000000..f1247233 --- /dev/null +++ b/web-ui/test/unit/common/footer/footer.spec.js @@ -0,0 +1,17 @@ +import { shallow } from 'enzyme'; +import expect from 'expect'; +import React from 'react'; +import { Footer } from 'src/common/footer/footer'; + +describe('Footer', () => { + let footer; + + beforeEach(() => { + const mockTranslations = key => key; + footer = shallow(<Footer t={mockTranslations} />); + }); + + it('renders the footer content', () => { + expect(footer.find('footer').text()).toContain('footer-text'); + }); +}); |