client/src/__tests__/App.test.js
author ymh <ymh.work@gmail.com>
Mon, 19 Jun 2017 17:56:43 +0200
changeset 55 a2761c5be551
parent 8 6f572b6b6be3
child 168 ea92f4fe783d
permissions -rw-r--r--
put APIClient in context

import React from 'react';
import ReactDOM from 'react-dom';
import {Provider} from 'react-redux';

import App from '../App';
import configureStore from '../store/configureStore';

beforeAll(() => {
  window.getSelection = () => {
    return {
      removeAllRanges: () => {}
    };
  };
});

const store = configureStore();

it('renders without crashing', () => {
  const div = document.createElement('div');
  ReactDOM.render(
    <Provider store={store}>
      <App />
    </Provider>,
    div);
});