diff --git a/.coveragerc b/.coveragerc index e4e35b28b..8b652710b 100644 --- a/.coveragerc +++ b/.coveragerc @@ -1,5 +1,6 @@ [run] source = xknx +relative_files = True omit = diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 000000000..4a45eabde --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,62 @@ +name: CI + +on: + push: + branches: + - '**' # run on all branches + pull_request: + branches: + - '**' # run on all branches + +jobs: + build: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: [3.7, 3.8, 3.9] + steps: + - uses: actions/checkout@v2 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Cache pip packages + uses: actions/cache@v2 + env: + cache-name: cache-pypi-modules + with: + # pip cache files are stored in `~/.cache/pip` on Linux + path: ~/.cache/pip + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('requirements/production.txt', 'requirements/testing.txt') }} + restore-keys: | + ${{ runner.os }}-build-${{ env.cache-name }}- + - name: Cache pre-commit packages + uses: actions/cache@v2 + env: + cache-name: cache-pre-commit + with: + # pre-commit cache files are usually stored in `~/.cache/pre-commit` on Linux + path: ~/.cache/pre-commit + key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('.pre-commit-config.yaml') }} + restore-keys: | + ${{ runner.os }}-build-${{ env.cache-name }}- + - name: Install dependencies + run: | + pip install -r requirements/testing.txt + - name: CI + run: | + tox + - name: Coveralls + uses: johanneswilm/coveralls-python-action@develop + with: + parallel: true + flag-name: Unit Test + + coveralls_finish: + needs: build + runs-on: ubuntu-latest + steps: + - name: Coveralls Finished + uses: johanneswilm/coveralls-python-action@develop + with: + parallel-finished: true \ No newline at end of file diff --git a/.pylintrc b/.pylintrc index deac14bc0..750cecbae 100644 --- a/.pylintrc +++ b/.pylintrc @@ -19,6 +19,7 @@ extension-pkg-whitelist=netifaces # inconsistent-return-statements - doesn't handle raise # too-many-ancestors - it's too strict. # wrong-import-order - isort guards this +# unsubscriptable-object - https://github.com/PyCQA/pylint/issues/3882 # fixme - TODO disable= format, @@ -43,7 +44,8 @@ disable= too-many-statements, too-many-boolean-expressions, unused-argument, - wrong-import-order + wrong-import-order, + unsubscriptable-object # enable useless-suppression temporarily every now and then to clean them up enable= use-symbolic-message-instead diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index a3753b839..000000000 --- a/.travis.yml +++ /dev/null @@ -1,23 +0,0 @@ -os: linux -language: python - -jobs: - include: - - python: "3.8" - env: TOXENV=pylint - - python: "3.8" - env: TOXENV=lint - - python: "3.7" - env: TOXENV=py37 - - python: "3.8" - env: TOXENV=py38 - - python: "3.9" - env: TOXENV=py39 - after_success: coveralls - -cache: - directories: - - $HOME/.cache/pip -# command to install dependencies -install: "pip install -r requirements/testing.txt" -script: travis_wait tox diff --git a/changelog.md b/changelog.md index f1c1fa1aa..da63d2e15 100644 --- a/changelog.md +++ b/changelog.md @@ -5,6 +5,7 @@ ### Internals - Telegram: `group_address` renamed to `destination_address`, to prepare support for other APCI services. +- Farewell Travis CI; Welcome Github Actions! ## 0.15.6 Bugfix for StateUpater 2020-11-26