* MM-29024 Detox/E2E: Add unit and e2e tests for disabled mobile upload * Simplified element call * Remove extra lines * Added e2e for mobile upload enabled - quick actions * Fix upload item snap file * Added check for license * Fix lint * Update function export Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
25 lines
695 B
JavaScript
25 lines
695 B
JavaScript
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
|
// See LICENSE.txt for license information.
|
|
|
|
import React from 'react';
|
|
import {shallowWithIntl} from 'test/intl-test-helper';
|
|
|
|
import {Preferences} from '@mm-redux/constants';
|
|
import UploadRemove from './upload_remove';
|
|
|
|
describe('UploadRemove', () => {
|
|
const props = {
|
|
onPress: jest.fn(),
|
|
channelId: 'channel-id',
|
|
clientId: 'client-id',
|
|
theme: Preferences.THEMES.default,
|
|
};
|
|
|
|
test('should match, full snapshot', () => {
|
|
const wrapper = shallowWithIntl(
|
|
<UploadRemove {...props}/>,
|
|
);
|
|
|
|
expect(wrapper.getElement()).toMatchSnapshot();
|
|
});
|
|
});
|