diff --git a/.github/workflows/linting.yml b/.github/workflows/linting.yml new file mode 100644 index 0000000..b366079 --- /dev/null +++ b/.github/workflows/linting.yml @@ -0,0 +1,25 @@ +--- +name: "linting" +on: + pull_request: + push: + branches: + - "main" +jobs: + lint: + name: "Lint" + runs-on: "ubuntu-latest" + steps: + - name: "Check out repository" + uses: "actions/checkout@v3" + - name: "Set up Python" + uses: "actions/setup-python@v3" + with: + python-version: "3.9" + - name: "Install tox" + run: | + python -m pip install --upgrade pip + pip install tox + - name: "Run tox" + run: | + tox -e linting diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 5adcbc7..3760833 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,5 +1,5 @@ --- -name: "sqlitefid tests" +name: "unit tests" on: pull_request: push: @@ -18,9 +18,9 @@ jobs: toxenv: "py310" steps: - name: "Check out repository" - uses: "actions/checkout@v2" + uses: "actions/checkout@v3" - name: "Set up Python ${{ matrix.python-version }}" - uses: "actions/setup-python@v2" + uses: "actions/setup-python@v3" with: python-version: "${{ matrix.python-version }}" - name: "Install OS packages" @@ -33,7 +33,7 @@ jobs: run: | echo "::set-output name=dir::$(pip cache dir)" - name: "Cache pip packages" - uses: "actions/cache@v2" + uses: "actions/cache@v3" with: path: "${{ steps.pip-cache.outputs.dir }}" key: "${{ runner.os }}-pip-${{ hashFiles('**/base.txt', '**/local.txt') }}" @@ -48,20 +48,3 @@ jobs: TOXENV: ${{ matrix.toxenv }} run: | tox - lint: - name: "Lint" - runs-on: "ubuntu-18.04" - steps: - - name: "Check out repository" - uses: "actions/checkout@v2" - - name: "Set up Python" - uses: "actions/setup-python@v2" - with: - python-version: "3.9" - - name: "Install tox" - run: | - python -m pip install --upgrade pip - pip install tox - - name: "Run tox" - run: | - tox -e linting