name: pytest

on: [push, pull_request]

jobs:
  test-ubuntu:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8, 3.9]
    steps:
    - uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
        pip install -r requirements-jax.txt
        pip install -r requirements-test.txt
        pip install .
    - name: Test with pytest
      run: |
        pip install pytest
        # Isolate the float64 test because it needs to set a flag at start-up,
        # so no other tests can be run before it.
        pytest haiku/_src/integration/float64_test.py
        pytest -n "$(grep -c ^processor /proc/cpuinfo)" haiku --ignore=haiku/_src/integration/float64_test.py

name: pytest

on: [push, pull_request]

jobs:
  test-ubuntu:
    runs-on: ubuntu-latest
    strategy:
      matrix:
        python-version: [3.6, 3.7, 3.8]
    steps:
    - uses: actions/checkout@v2
    - name: Set up Python ${{ matrix.python-version }}
      uses: actions/setup-python@v1
      with:
        python-version: ${{ matrix.python-version }}
    - name: Install dependencies
      run: |
        python -m pip install --upgrade pip
        pip install -r requirements.txt
        pip install -r requirements-jax.txt
        pip install -r requirements-test.txt
        pip install .
    - name: Test with pytest
      run: |
        pip install pytest
        # Isolate the float64 test because it needs to set a flag at start-up,
        # so no other tests can be run before it.
        pytest haiku/_src/integration/float64_test.py
        pytest -n "$(grep -c ^processor /proc/cpuinfo)" haiku --ignore=haiku/_src/integration/float64_test.py

Remove 3.9 tests since TF 2.4.0 only supports <=3.8.
Remove 3.9 tests since TF 2.4.0 only supports <=3.8.

PiperOrigin-RevId: 351993947
Change-Id: I9356847160c1d5e701d5f1314fa7811025fc83ac
