|
@@ -4,7 +4,18 @@ import PageLoader from '../PageLoader';
|
|
|
|
|
|
describe('PageLoader', () => {
|
|
|
it('matches the snapshot', () => {
|
|
|
- const component = mount(<PageLoader />);
|
|
|
- expect(component).toMatchSnapshot();
|
|
|
+ expect(mount(<PageLoader />)).toMatchSnapshot();
|
|
|
+ });
|
|
|
+
|
|
|
+ it('renders half-height page loader by default', () => {
|
|
|
+ const wrapper = mount(<PageLoader />);
|
|
|
+ expect(wrapper.exists('.hero.is-halfheight')).toBeTruthy();
|
|
|
+ expect(wrapper.exists('.hero.is-fullheight-with-navbar')).toBeFalsy();
|
|
|
+ });
|
|
|
+
|
|
|
+ it('renders fullheight page loader', () => {
|
|
|
+ const wrapper = mount(<PageLoader fullHeight />);
|
|
|
+ expect(wrapper.exists('.hero.is-halfheight')).toBeFalsy();
|
|
|
+ expect(wrapper.exists('.hero.is-fullheight-with-navbar')).toBeTruthy();
|
|
|
});
|
|
|
});
|