# This workflow will install Python dependencies, run tests and lint with a variety of Python versions # For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions name: Enhancer on: push: branches: [ dev ] pull_request: branches: [ dev ] jobs: build: runs-on: ubuntu-latest strategy: matrix: python-version: [3.8] steps: - uses: actions/checkout@v2 - name: Set up Python uses: actions/setup-python@v1.1.1 env : ACTIONS_ALLOW_UNSECURE_COMMANDS : true with: python-version: ${{ matrix.python-version }} - name: Cache pip uses: actions/cache@v1 with: path: ~/.cache/pip # This path is specific to Ubuntu # Look to see if there is a cache hit for the corresponding requirements file key: ${{ runner.os }}-pip-${{ hashFiles('requirements.txt') }} restore-keys: | ${{ runner.os }}-pip- ${{ runner.os }}- # You can test your matrix by printing the current Python version - name: Display Python version run: python -c "import sys; print(sys.version)" - name: Install dependencies run: | python -m pip install --upgrade pip sudo apt-get install libsndfile1 pip install -r requirements.txt pip install black pytest-cov - name: Install enhancer run: | pip install -e .[dev,testing] - name: Run black run: black --check . --exclude enhancer/version.py - name: Test with pytest run: pytest tests --cov=enhancer/