Skip to content

Commit

Permalink
lint and test concurrently
Browse files Browse the repository at this point in the history
  • Loading branch information
danabens committed Jan 31, 2020
1 parent ff4fedf commit cef2d58
Showing 1 changed file with 21 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Build and Release
name: Test and Release

on:
pull_request:
Expand All @@ -7,9 +7,27 @@ on:
release:
types: [published]
push:
paths:
- 'src/**'
- 'tests/**'

jobs:
build:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Setup Python
uses: actions/setup-python@v1
- name: Install Dependencies
run: pip install tox
- name: Flake8
run: tox -e flake8
- name: Black Check
run: tox -e black-check
- name: Pylint
run: tox -e pylint

test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
Expand All @@ -27,12 +45,6 @@ jobs:
python-version: 3.7
- name: Install Dependencies
run: pip install tox
- name: Flake8
run: tox -e flake8
- name: Black Check
run: tox -e black-check
- name: Pylint
run: tox -e pylint
# runs unit tests for each python version
- name: Unit Tests
run: tox -- tests/unit
Expand All @@ -57,7 +69,7 @@ jobs:
CODECOV_UPLOAD_TOKEN: ${{ secrets.AWS_ACCESS_KEY_ID }}

release:
needs: build
needs: [test, lint]
if: github.event_name == 'release' && github.repository == 'aws/sagemaker-experiments'
runs-on: ubuntu-latest
steps:
Expand Down

0 comments on commit cef2d58

Please sign in to comment.