Files
Jesús Espino 593a8bbd00 MM-13272: New LoadingWrapper component (#2149)
* MM-13272: Adding Loading Component

* MM-13272: Improving loaders consistency

* Updated i18n/en.json

* Applying proposed changes

* Lot of naming and path changes

* Changing classes names
2018-12-19 05:28:56 +01:00

38 lines
805 B
React

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react';
import {shallow} from 'enzyme';
import LoadingBars from './loading_bars.jsx';
describe('components/widgets/loading/LoadingBars', () => {
test('showing bars with text', () => {
const wrapper = shallow(<LoadingBars text='test'/>);
expect(wrapper).toMatchInlineSnapshot(`
<span
className="LoadingBars with-text"
>
<img
className="spinner"
src={null}
/>
test
</span>
`);
});
test('showing bars without text', () => {
const wrapper = shallow(<LoadingBars/>);
expect(wrapper).toMatchInlineSnapshot(`
<span
className="LoadingBars"
>
<img
className="spinner"
src={null}
/>
</span>
`);
});
});