mattermost-mobile/app/screens/long_post/long_post.test.js
Elias Nahum bd7afae6f0
Always load the thread & modify thread selector (#4771)
* Always load the thread & modify thread selector

* review feedback
2020-09-08 13:09:46 -03:00

32 lines
808 B
JavaScript

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React from 'react';
import Preferences from '@mm-redux/constants/preferences';
import {shallowWithIntl} from 'test/intl-test-helper';
import LongPost from './long_post';
jest.mock('react-native-file-viewer', () => ({
open: jest.fn(),
}));
describe('LongPost', () => {
const baseProps = {
actions: {
getPostThread: jest.fn(),
selectPost: jest.fn(),
},
postId: 'post-id',
theme: Preferences.THEMES.default,
isLandscape: false,
};
test('should match snapshot', () => {
const wrapper = shallowWithIntl(<LongPost {...baseProps}/>);
expect(wrapper.instance()).toMatchSnapshot();
});
});