title: jest: Test suite failed to run, SyntaxError: Unexpected token import
body: <p>This is my <a href="https://facebook.github.io/jest/docs/configuration.html" rel="noreferrer">jest configuration</a> from the package.json file:</p>
  
  <pre><code>"jest": {
      "automock": false,
      "browser": true,
      "moduleNameMapper": {
        "\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "./app/tests/mocks/FileMock.js",
        "\\.(css|less)$": "identity-obj-proxy"
      },
      "moduleFileExtensions": [
        "js",
        "jsx"
      ],
      "moduleDirectories": [
        "node_modules"
      ],
      "transform": {
        "^.+\\.jsx?$": "./node_modules/babel-jest",
        "\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "./app/tests/mocks/FileTransformer.js"
      },
      "testEnvironment": "jsdom",
      "testPathDirs": [
        "./app/tests"
      ],
      "testRegex": ".*.test.js",
      "verbose": true
    }
  </code></pre>
  
  <p>And the .babelrc file located in my root folder:</p>
  
  <pre><code>{
    "plugins": ["syntax-dynamic-import", "transform-runtime"],
    "presets": [
      [
        "es2015",
        {
          "modules": false
        }
      ],
      "react",
      "stage-0"
    ],
    "env": {
      "start": {
        "presets": [
          "react-hmre"
        ]
      }
    }
  }
  </code></pre>
  
  <p>According to the documentation found at the jest <a href="https://facebook.github.io/jest/docs/getting-started.html#content" rel="noreferrer">getting started page</a> this is everything I need for babel to work it's magic.</p>
  
  <p>Regardless, this test:</p>
  
  <pre><code>import React from 'react';
  import {shallow} from 'enzyme';
  import Landing from '../components/Landing.component';
  
  describe('&lt;Landing/&gt;', () =&gt; {
    it('should render a header to the page', () =&gt; {
      const landing = shallow(&lt;Landing/&gt;);
      expect(landing.find('h1').text()).toBe('This is the Landing component');
    });
  });
  </code></pre>
  
  <p>returns:</p>
  
  <pre><code>FAIL  app/tests/Landing.component.test.js   
   ● Test suite failed to run
  
     /Users/shooshte/PersonalProjects/surviveJS/app/tests/Landing.component.test.js:1
     ({"Object.&lt;anonymous&gt;":function(module,exports,require,__dirname,__filename,global,jest){import React from 'react';
                                                                                              ^^^^^^
     SyntaxError: Unexpected token import
  
       at transformAndBuildScript (node_modules/jest-runtime/build/transform.js:320:12)
  </code></pre>
  
  <p>What am I doing wrong?</p>