Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 17 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,24 @@ jobs:
- name: Test with pytest via tox
run: |
tox -e gh
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3

- name: Coveralls Parallel
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
flag-name: Unittests-${{ matrix.os }}-${{ matrix.python-version }}
parallel: true
path-to-lcov: ./coverage.lcov

coveralls:
needs: test
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
with:
fail_ci_if_error: true
github-token: ${{ secrets.github_token }}
parallel-finished: true

static-code-analysis:
runs-on: ubuntu-latest
Expand Down
6 changes: 3 additions & 3 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ python-can
:target: https://app.travis-ci.com/github/hardbyte/python-can
:alt: Travis CI Server for develop branch

.. |coverage| image:: https://codecov.io/gh/hardbyte/python-can/branch/develop/graph/badge.svg
:target: https://codecov.io/gh/hardbyte/python-can/branch/develop
:alt: Test coverage reports on Codecov.io
.. |coverage| image:: https://coveralls.io/repos/github/hardbyte/python-can/badge.svg?branch=develop
:target: https://coveralls.io/github/hardbyte/python-can?branch=develop
:alt: Test coverage reports on Coveralls.io

.. |mergify| image:: https://img.shields.io/endpoint.svg?url=https://api.mergify.com/v1/badges/hardbyte/python-can&style=flat
:target: https://mergify.io
Expand Down
2 changes: 1 addition & 1 deletion doc/development.rst
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ The modules in ``python-can`` are:
Creating a new Release
----------------------

- Release from the ``master`` branch (except for pre-releases).
- Release from the ``main`` branch (except for pre-releases).
- Update the library version in ``__init__.py`` using `semantic versioning <http://semver.org>`__.
- Check if any deprecations are pending.
- Run all tests and examples against available hardware.
Expand Down
5 changes: 3 additions & 2 deletions test/test_message_class.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import pickle
from datetime import timedelta

from hypothesis import given, settings
from hypothesis import HealthCheck, given, settings
import hypothesis.errors
import hypothesis.strategies as st

Expand Down Expand Up @@ -42,12 +42,13 @@ class TestMessageClass(unittest.TestCase):
# The first run may take a second on CI runners and will hit the deadline
@settings(
max_examples=2000,
suppress_health_check=[HealthCheck.too_slow],
deadline=None if IS_GITHUB_ACTIONS else timedelta(milliseconds=500),
)
@pytest.mark.xfail(
IS_WINDOWS and IS_PYPY,
raises=hypothesis.errors.Flaky,
reason="Hypothesis generates inconistent timestamp floats on Windows+PyPy-3.7",
reason="Hypothesis generates inconsistent timestamp floats on Windows+PyPy-3.7",
)
def test_methods(self, **kwargs):
is_valid = not (
Expand Down
12 changes: 5 additions & 7 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ isolated_build = true
deps =
pytest==7.1.*,>=7.1.2
pytest-timeout==2.0.2
pytest-cov==3.0.0
coverage==6.3
codecov==2.1.12
coveralls==3.3.1
pytest-cov==4.0.0
coverage==6.5.0
hypothesis~=6.35.0
pyserial~=3.5
parameterized~=0.8
Expand All @@ -24,22 +24,20 @@ recreate = True
passenv =
CI
GITHUB_*
COVERALLS_*
PY_COLORS

[testenv:travis]
passenv =
CI
TRAVIS
TRAVIS_*
CODECOV_*
TEST_SOCKETCAN

commands_post =
codecov -X gcov

[pytest]
testpaths = test
addopts = -v --timeout=300 --cov=can --cov-config=tox.ini --cov-report=xml --cov-report=term
addopts = -v --timeout=300 --cov=can --cov-config=tox.ini --cov-report=lcov --cov-report=term


[coverage:run]
Expand Down