name: spglib test using conda

on:
  push:
    branches-ignore:
      - rc
      - master

jobs:
  build-linux:
    runs-on: ubuntu-latest
    strategy:
      max-parallel: 5

    steps:
    - uses: actions/checkout@v2
    - name: Set up Python 3.8
      uses: actions/setup-python@v2
      with:
        python-version: 3.8
    - name: Add conda to system path
      run: |
        # $CONDA is an environment variable pointing to the root of the miniconda directory
        echo $CONDA/bin >> $GITHUB_PATH
    - name: Install dependencies
      run: |
        conda install --yes -c conda-forge python=3.8
        conda install --yes -c conda-forge numpy compilers pip pytest codecov pytest-cov
    - name: Setup spglib
      working-directory: ./python
      run: |
        ./get_nanoversion.sh
        cat __nanoversion__.txt
        python setup.py build
        pip install -e .
    - name: Test with pytest
      working-directory: ./python
      run: |
        pytest --cov=./ --cov-report=xml
    - name: Upload coverage to Codecov
      working-directory: ./python
      uses: codecov/codecov-action@v1
      with:
        verbose: true
Add github workflow for automatic test
Add github workflow for automatic test
