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
24 changes: 0 additions & 24 deletions .appveyor.yml

This file was deleted.

6 changes: 1 addition & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ python-can

|release| |python_implementation| |downloads| |downloads_monthly| |formatter|

|docs| |build_travis| |build_appveyor| |coverage| |mergify|
|docs| |build_travis| |coverage| |mergify|

.. |release| image:: https://img.shields.io/pypi/v/python-can.svg
:target: https://pypi.python.org/pypi/python-can/
Expand Down Expand Up @@ -33,10 +33,6 @@ python-can
:target: https://travis-ci.com/hardbyte/python-can
:alt: Travis CI Server for develop branch

.. |build_appveyor| image:: https://img.shields.io/appveyor/ci/hardbyte/python-can/develop.svg?label=AppVeyor
:target: https://ci.appveyor.com/project/hardbyte/python-can/history
:alt: AppVeyor 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
Expand Down
29 changes: 12 additions & 17 deletions test/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
This module contains various configuration for the tests.

Some tests are skipped when run on a CI server because they are not
reproducible, see #243 (https://github.com/hardbyte/python-can/issues/243).
reproducible, see for example #243 and #940.
"""

import platform
Expand All @@ -20,23 +20,17 @@ def env(name: str) -> bool:

# see here for the environment variables that are set on the CI servers:
# - https://docs.travis-ci.com/user/environment-variables/
# - https://www.appveyor.com/docs/environment-variables/
# - https://docs.github.com/en/actions/reference/environment-variables#default-environment-variables

IS_TRAVIS = env("TRAVIS")
IS_APPVEYOR = env("APPVEYOR")
IS_GITHUB_ACTIONS = env("GITHUB_ACTIONS")

IS_CI = (
IS_TRAVIS
or IS_APPVEYOR
or IS_GITHUB_ACTIONS
or env("CI")
or env("CONTINUOUS_INTEGRATION")
)
IS_CI = IS_TRAVIS or IS_GITHUB_ACTIONS or env("CI") or env("CONTINUOUS_INTEGRATION")

if IS_APPVEYOR and IS_TRAVIS and IS_GITHUB_ACTIONS:
if IS_TRAVIS and IS_GITHUB_ACTIONS:
raise EnvironmentError(
"only one of IS_APPVEYOR and IS_TRAVIS and GITHUB_ACTIONS may be True at the same time"
f"only one of IS_TRAVIS ({IS_TRAVIS}) and IS_GITHUB_ACTIONS ({IS_GITHUB_ACTIONS}) may be True at the "
"same time"
)


Expand All @@ -47,19 +41,20 @@ def env(name: str) -> bool:
IS_LINUX = "linux" in _sys
IS_OSX = "darwin" in _sys
IS_UNIX = IS_LINUX or IS_OSX
del _sys

if (IS_WINDOWS and IS_LINUX) or (IS_LINUX and IS_OSX) or (IS_WINDOWS and IS_OSX):
raise EnvironmentError(
"only one of IS_WINDOWS ({}), IS_LINUX ({}) and IS_OSX ({}) ".format(
IS_WINDOWS, IS_LINUX, IS_OSX
)
+ "can be True at the same time "
+ '(platform.system() == "{}")'.format(platform.system())
f"only one of IS_WINDOWS ({IS_WINDOWS}), IS_LINUX ({IS_LINUX}) and IS_OSX ({IS_OSX}) "
f'can be True at the same time (platform.system() == "{platform.system()}")'
)


# ############################## Implementations

IS_PYPY = platform.python_implementation() == "PyPy"


# ############################## What tests to run

TEST_CAN_FD = True
Expand Down
4 changes: 2 additions & 2 deletions test/test_message_sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

from can import MessageSync, Message

from .config import IS_CI, IS_APPVEYOR, IS_TRAVIS, IS_OSX, IS_GITHUB_ACTIONS, IS_LINUX
from .config import IS_CI, IS_TRAVIS, IS_OSX, IS_GITHUB_ACTIONS, IS_LINUX
from .message_helper import ComparingMessagesTestCase
from .data.example_data import TEST_MESSAGES_BASE

Expand All @@ -31,7 +31,7 @@ def inc(value):


skip_on_unreliable_platforms = unittest.skipIf(
IS_APPVEYOR or (IS_TRAVIS and IS_OSX) or (IS_GITHUB_ACTIONS and not IS_LINUX),
(IS_TRAVIS and IS_OSX) or (IS_GITHUB_ACTIONS and not IS_LINUX),
"this environment's timings are too unpredictable",
)

Expand Down
11 changes: 0 additions & 11 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -31,17 +31,6 @@ passenv =
TRAVIS_*
TEST_SOCKETCAN

commands_post =
codecov -X gcov

[testenv:appveyor]
passenv =
CI
APPVEYOR
APPVEYOR_*

extras = neovi

commands_post =
codecov -X gcov

Expand Down