title: Getting an error when trying to import a component into Jest
body: <p>I am using React+Redux/Redux-thunk and I am trying to implement jest/enzyme. I was able to successfully make a passing test for the root component. However I'm stuck at a point where I am trying to make a new test file for another component. No matter what component I try to test (connected or not connected) I am getting the same error.</p>
  
  <pre><code> FAIL  src/views/LoginView/LoginView.test.jsx
    ● Test suite failed to run
  
      Expected the reducer to be a function.
  
        32 |   }
        33 | 
      &gt; 34 |   const store = middleware(createStore)(rootReducer, initialState);
           |                 ^
        35 |   const compressor = createCompressor();
        36 |   const persistor = persistStore(store, { transforms: [compressor] }, () =&gt; { store.getState(); });
        37 | 
  
    at createStore (node_modules/redux/lib/createStore.js:68:11)
    at node_modules/redux/lib/applyMiddleware.js:38:19
    at middleware (src/redux/configureStore.js:34:17)
    at Object.&lt;anonymous&gt; (src/main.jsx:78:37)
  </code></pre>
  
  <p>I am not able to even write my first test as it errors out while importing the component. </p>
  
  <p>The test file looks like this (pretty much blank) and it is in the same directory as the component LoginView.</p>
  
  <pre><code>import React               from 'react';
  import { shallow }         from 'enzyme';
  
  import LoginView       from './LoginView';
  
  test('passing test', () =&gt; {
  
  });
  </code></pre>
  
  <p>My jest.config.js file looks like this:</p>
  
  <pre><code>module.exports = {
    setupTestFrameworkScriptFile: '&lt;rootDir&gt;/test/setupTests.js',
  
    moduleNameMapper: {
      '\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$': '&lt;rootDir&gt;/__mocks__/fileMock.js',
  
      '\\.(css|less|scss)$': 'identity-obj-proxy',
      '^handsontable'      : 'handsontable',
    },
  
    modulePaths: [
      '&lt;rootDir&gt;/node_modules',
    ],
  
    transformIgnorePatterns: [
      'node_modules/(?!(react-joyride)/)',
    ],
  
    globals: {
      __API_BASE__        : '',
      __HOT_BUILD_DATE__  : '',
      __HOT_PACKAGE_NAME__: '',
      __HOT_VERSION__     : '',
      __HOT_BASE_VERSION__: '',
      __BASENAME__        : false,
      __DEBUG__           : false,
    },
  
    verbose: true,
  
  };
  </code></pre>
  
  <p>I'm using the following versions of everything: </p>
  
  <pre><code>"react": "^16.5.2",
  "babel-jest": "^23.6.0",
  "jest": "^23.6.0",
  "jest-enzyme": "^7.0.0",
  "enzyme": "^3.7.0",
  "enzyme-adapter-react-16": "^1.6.0",
  "redux": "^3.7.2",
  "redux-persist": "^5.5.0",
  "react-redux": "^5.0.6",
  "redux-raven-middleware": "^1.2.0",
  "redux-thunk": "^2.2.0",
  </code></pre>
  
  <p>I would appreciate any feedback or guidance on this topic as I am currently unable to write any tests on my components other than my root component.</p>
  
  <p>Thanks in advance!</p>