matrix:
  include:
    - language: python
      python:
        - "3.5"

      sudo: False

      addons:
          postgresql: "9.6"

      # command to install dependencies
      install:
          - pip install -r requirements.txt
          - pip install -r test-requirements.txt
          - pip install coveralls

      env: 
          - TEST=True DATABASE_URL=postgres://postgres@localhost/cellcountr_test

      before_script:
          - psql -c 'create database cellcountr_test;' -U postgres
          - npm install -g npm@'>=3'

      # command to run tests
      script: coverage run --source=cellcounter --omit='*migrations*' manage.py test

      after_success:
          coveralls

    - language: python
      python:
        - "3.5"
      node_js:
        - "12.6"

      sudo: False

      addons:
          postgresql: "9.6"

      # command to install dependencies
      install:
          - pip install -r requirements.txt
          - pip install -r test-requirements.txt
          - npm i -g npm
          - npm ci --verbose

      before_script:
          - psql -c 'create database cellcountr_test;' -U postgres
          #- npm install -g npm@'>=3'
          #- npm install -g mocha

      # command to run tests
      script: bash test_integration.sh


matrix:
  include:
    - language: python
      python:
        - "3.5"

      sudo: False

      addons:
          postgresql: "9.6"

      # command to install dependencies
      install:
          - pip install -r requirements.txt
          - pip install -r test-requirements.txt
          - pip install coveralls

      env: 
          - TEST=True DATABASE_URL=postgres://postgres@localhost/cellcountr_test

      before_script:
          - psql -c 'create database cellcountr_test;' -U postgres
          - npm install -g npm@'>=3'

      # command to run tests
      script: coverage run --source=cellcounter --omit='*migrations*' manage.py test

      after_success:
          coveralls

    - language: python
      python:
        - "3.5"
      node_js:
        - "12.6"

      sudo: False

      addons:
          postgresql: "9.6"

      # command to install dependencies
      install:
          - pip install -r requirements.txt
          - pip install -r test-requirements.txt
          - npm i -g npm
          - npm ci --verbose

      env: 
          - PATH=$PATH:$HOME/node_modules/.bin

      before_script:
          - psql -c 'create database cellcountr_test;' -U postgres
          #- npm install -g npm@'>=3'
          #- npm install -g mocha

      # command to run tests
      script: bash test_integration.sh


Add Node bin to path.
Add Node bin to path.
