title: TravisCI with npm run test from create react app
body: <p>I am trying to perform automated testing with <code>TravisCI</code> with my project generated by create react app.</p>
  
  <p>I was told that <code>npm run test -- --coverage</code> should stop the <code>watch mode</code> or the prompt from showing up when running <code>npm run test</code>. However I am still seeing the prompt.</p>
  
  <pre><code>Watch Usage
   › Press f to run only failed tests.
   › Press o to only run tests related to changed files.
   › Press q to quit watch mode.
   › Press p to filter by a filename regex pattern.
   › Press t to filter by a test name regex pattern.
   › Press Enter to trigger a test run.
  </code></pre>
  
  <p>Updates:</p>
  
  <p>Project structure</p>
  
  <pre><code>/redribbon
    .travis.yml
    docker-compose.yml
    /client
      package.json
      Dockerfile
      Dockerfile.dev
    /server
  </code></pre>
  
  <p>I've learned by default TravisCI will have <code>CI=true</code> set automatically. Currently, my <code>npm run test</code> in <code>[package.json][1]</code> has not been touched. </p>
  
  <p><code>.travis.yml</code></p>
  
  <pre><code>sudo: required    
  services:
    - docker
  before_install:
    - docker build -t bradford/redribbon-client -f ./client/Dockerfile.dev ./client
  script:
    - docker run bradford/redribbon-client npm run test
  </code></pre>
  
  <p>TravisCI output can be seen <a href="https://travis-ci.org/liondancer/redribbon/builds/528117890" rel="nofollow noreferrer">here</a></p>
  
  <p>Without TravisCI, when I run the command <code>npm run test</code> or <code>npm test</code> this is my output:</p>
  
  <pre><code>No tests found related to files changed since last commit.
  Press `a` to run all tests, or run Jest with `--watchAll`.
  
  Watch Usage
   › Press a to run all tests.
   › Press f to run only failed tests.
   › Press q to quit watch mode.
   › Press p to filter by a filename regex pattern.
   › Press t to filter by a test name regex pattern.
   › Press Enter to trigger a test run.
  </code></pre>
  
  <p>If I added <code>CI=true</code> --> <code>"test": "CI=true react-scripts test",</code></p>
  
  <p>This is my output:</p>
  
  <pre><code>$ npm test
  
  &gt; client@0.1.0 test /Users/bli1/Development/projects/sideprojects/redribbon/client
  &gt; CI=true react-scripts test
  
  No tests found, exiting with code 1
  Run with `--passWithNoTests` to exit with code 0
  In /Users/bli1/Development/projects/sideprojects/redribbon/client
    14 files checked.
    testMatch: /Users/bli1/Development/projects/sideprojects/redribbon/client/src/**/__tests__/**/*.{js,jsx,ts,tsx}, /Users/bli1/Development/projects/sideprojects/redribbon/client/src/**/*.{spec,test}.{js,jsx,ts,tsx} - 0 matches
    testPathIgnorePatterns: /node_modules/ - 14 matches
    testRegex:  - 0 matches
  Pattern:  - 0 matches
  npm ERR! Test failed.  See above for more details.
  </code></pre>