Skip to content
Permalink
Browse files

Setup CI with Github Actions (sdispater#1347)

* Setup basic Github actions

* Remove Travis and Appveyor config files

* Update pre-commit configuration
  • Loading branch information
sdispater committed Sep 2, 2019
1 parent cd3ad8c commit 0b38fada8dfc41bf6a47288781785373d663185e
Showing with 101 additions and 68 deletions.
  1. +0 −28 .appveyor.yml
  2. +96 −0 .github/workflows/main.yml
  3. +1 −1 .pre-commit-config.yaml
  4. +0 −35 .travis.yml
  5. +4 −4 tests/masonry/builders/test_complete.py

This file was deleted.

@@ -0,0 +1,96 @@
name: Tests

on: [push]

jobs:
Linting:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v1
- name: Set up Python 3.7
uses: actions/setup-python@v1
with:
python-version: 3.7
- name: Linting
run: |
pip install pre-commit
pre-commit run --all-files
Linux:
needs: Linting
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [2.7, 3.5, 3.6, 3.7]

steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
run: |
python get-poetry.py --preview -y
source $HOME/.poetry/env
- name: Install dependencies
run: |
source $HOME/.poetry/env
poetry install
- name: Test
run: |
source $HOME/.poetry/env
poetry run pytest -q tests
MacOS:
needs: Linting
runs-on: macos-latest
strategy:
matrix:
python-version: [2.7, 3.5, 3.6, 3.7]

steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
run: |
python get-poetry.py --preview -y
source $HOME/.poetry/env
- name: Install dependencies
run: |
source $HOME/.poetry/env
poetry install
- name: Test
run: |
source $HOME/.poetry/env
poetry run pytest -q tests
Windows:
needs: Linting
runs-on: windows-latest
strategy:
matrix:
python-version: [2.7, 3.5, 3.6, 3.7]

steps:
- uses: actions/checkout@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v1
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
run: |
python get-poetry.py --preview -y
SET PATH=%USERPROFILE%\\.poetry\\bin;%PATH%
- name: Install dependencies
run: |
SET PATH=%USERPROFILE%\\.poetry\\bin;%PATH%
poetry install
- name: Test
run: |
SET PATH=%USERPROFILE%\\.poetry\\bin;%PATH%
poetry run pytest -q tests
@@ -3,4 +3,4 @@ repos:
rev: stable
hooks:
- id: black
python_version: python3.6
language_version: python3.6

This file was deleted.

@@ -37,8 +37,8 @@ def clear_samples_dist():


@pytest.mark.skipif(
sys.platform == "win32" and sys.version_info <= (3, 4),
reason="Disable test on Windows for Python <=3.4",
sys.platform == "win32" and sys.version_info <= (3, 6),
reason="Disable test on Windows for Python <=3.6",
)
def test_wheel_c_extension():
module_path = fixtures_dir / "extended"
@@ -94,8 +94,8 @@ def test_wheel_c_extension():


@pytest.mark.skipif(
sys.platform == "win32" and sys.version_info <= (3, 4),
reason="Disable test on Windows for Python <=3.4",
sys.platform == "win32" and sys.version_info <= (3, 6),
reason="Disable test on Windows for Python <=3.6",
)
def test_wheel_c_extension_src_layout():
module_path = fixtures_dir / "src_extended"

0 comments on commit 0b38fad

Please sign in to comment.
You can’t perform that action at this time.