name: CI
on: [push, pull_request]
jobs:
  build:
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [macos-latest, windows-latest, ubuntu-latest]
        python-version: [2.7, 3.6, 3.7, 3.8, 3.9, pypy-3.6, pypy-3.7]
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-python@v2
        with:
          python-version: ${{ matrix.python-version }}
      # https://github.com/actions/cache/blob/main/examples.md#using-a-script-to-get-cache-location
      - id: pip-cache
        run: python -c "from pip._internal.locations import USER_CACHE_DIR; print('::set-output name=dir::' + USER_CACHE_DIR)"
      - uses: actions/cache@v1
        with:
          path: ${{ steps.pip-cache.outputs.dir }}
          key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
          restore-keys: |
            ${{ runner.os }}-pip-
      - env:
          PKG_CONFIG_PATH: /usr/local/opt/icu4c/lib/pkgconfig
        run: pip install .[test]
      - run: nosetests

name: CI
on: [push, pull_request]
jobs:
  build:
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        os: [macos-latest, windows-latest, ubuntu-latest]
        python-version: [3.6, 3.7, 3.8, 3.9, pypy-3.6, pypy-3.7]
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-python@v2
        with:
          python-version: ${{ matrix.python-version }}
      # https://github.com/actions/cache/blob/main/examples.md#using-a-script-to-get-cache-location
      - id: pip-cache
        run: python -c "from pip._internal.locations import USER_CACHE_DIR; print('::set-output name=dir::' + USER_CACHE_DIR)"
      - uses: actions/cache@v1
        with:
          path: ${{ steps.pip-cache.outputs.dir }}
          key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
          restore-keys: |
            ${{ runner.os }}-pip-
      - run: pip install .[test]
      - run: nosetests

Stop testing on Python 2.7 (PyICU problems)
build: Stop testing on Python 2.7 (PyICU problems)
