Skip to content

Commit

Permalink
chore(update-modal): Fix the test failure issue
Browse files Browse the repository at this point in the history
  • Loading branch information
placideirandora committed Oct 29, 2019
1 parent e2e5222 commit 685db12
Showing 1 changed file with 2 additions and 19 deletions.
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
/* eslint-disable react/jsx-props-no-spreading */
import React from 'react';
import { mount, shallow } from 'enzyme';
import { BrowserRouter } from 'react-router-dom';
import { Provider } from 'react-redux';
import ViewProfileComponent, { ProfileComponent } from '../ViewProfileComponent';
import store from '../../../../app/store/index';
import { shallow } from 'enzyme';
import { ProfileComponent } from '../ViewProfileComponent';

const renderProfile = () => {
const initialProps = {
Expand All @@ -27,20 +24,6 @@ const renderProfile = () => {
return shallow(<ProfileComponent {...props} />);
};

describe('Rendering the View Profile Component', () => {
const wrapper = mount(
<Provider store={store}>
<BrowserRouter>
<ViewProfileComponent />
</BrowserRouter>
</Provider>
);

it('should render the component', () => {
expect(wrapper.exists()).toBe(true);
});
});

describe('View Profile Component Tests', () => {
const wrapper = renderProfile();
const button = wrapper.find('button');
Expand Down

0 comments on commit 685db12

Please sign in to comment.