Skip to content

Commit 7c521af

Browse files
authored
Update Test Dependencies (#1963)
* update test dependencies * use pytest-modern for prettier pytest output * update ruff * fix coveralls flag-name * checkout to fix failing "git log" cmd
1 parent a4f4742 commit 7c521af

File tree

4 files changed

+19
-12
lines changed

4 files changed

+19
-12
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,14 +51,15 @@ jobs:
5151
uses: coverallsapp/github-action@v2
5252
with:
5353
github-token: ${{ secrets.github_token }}
54-
flag-name: Unittests-${{ matrix.os }}-${{ matrix.python-version }}
54+
flag-name: Unittests-${{ matrix.os }}-${{ matrix.env }}
5555
parallel: true
5656
path-to-lcov: ./coverage.lcov
5757

5858
coveralls:
5959
needs: test
6060
runs-on: ubuntu-latest
6161
steps:
62+
- uses: actions/checkout@v4
6263
- name: Coveralls Finished
6364
uses: coverallsapp/github-action@v2
6465
with:

can/broadcastmanager.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ class _Pywin32Event:
3939

4040
class _Pywin32:
4141
def __init__(self) -> None:
42-
import pywintypes # pylint: disable=import-outside-toplevel,import-error
43-
import win32event # pylint: disable=import-outside-toplevel,import-error
42+
import pywintypes # noqa: PLC0415 # pylint: disable=import-outside-toplevel,import-error
43+
import win32event # noqa: PLC0415 # pylint: disable=import-outside-toplevel,import-error
4444

4545
self.pywintypes = pywintypes
4646
self.win32event = win32event

can/interfaces/systec/structures.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ class CanMsg(Structure):
5151
DWORD,
5252
), # Receive time stamp in ms (for transmit messages no meaning)
5353
]
54+
__hash__ = Structure.__hash__
5455

5556
def __init__(
5657
self, id_=0, frame_format=MsgFrameFormat.MSG_FF_STD, data=None, dlc=None
@@ -116,6 +117,7 @@ class Status(Structure):
116117
("m_wCanStatus", WORD), # CAN error status (see enum :class:`CanStatus`)
117118
("m_wUsbStatus", WORD), # USB error status (see enum :class:`UsbStatus`)
118119
]
120+
__hash__ = Structure.__hash__
119121

120122
def __eq__(self, other):
121123
if not isinstance(other, Status):
@@ -171,6 +173,7 @@ class InitCanParam(Structure):
171173
WORD,
172174
), # number of transmit buffer entries (default is 4096)
173175
]
176+
__hash__ = Structure.__hash__
174177

175178
def __init__(
176179
self, mode, BTR, OCR, AMR, ACR, baudrate, rx_buffer_entries, tx_buffer_entries
@@ -277,6 +280,7 @@ class HardwareInfoEx(Structure):
277280
("m_dwUniqueId3", DWORD),
278281
("m_dwFlags", DWORD), # additional flags
279282
]
283+
__hash__ = Structure.__hash__
280284

281285
def __init__(self):
282286
super().__init__(sizeof(HardwareInfoEx))
@@ -389,6 +393,7 @@ class ChannelInfo(Structure):
389393
WORD,
390394
), # CAN status (same as received by method :meth:`UcanServer.get_status`)
391395
]
396+
__hash__ = Structure.__hash__
392397

393398
def __init__(self):
394399
super().__init__(sizeof(ChannelInfo))

pyproject.toml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -88,18 +88,19 @@ docs = [
8888
]
8989
lint = [
9090
"pylint==3.3.*",
91-
"ruff==0.11.12",
91+
"ruff==0.12.5",
9292
"black==25.1.*",
93-
"mypy==1.16.*",
93+
"mypy==1.17.*",
9494
]
9595
test = [
96-
"pytest==8.3.*",
97-
"pytest-timeout==2.1.*",
98-
"coveralls==3.3.1",
99-
"pytest-cov==4.0.0",
100-
"coverage==6.5.0",
101-
"hypothesis~=6.35.0",
102-
"parameterized~=0.8",
96+
"pytest==8.4.*",
97+
"pytest-timeout==2.4.*",
98+
"pytest-modern==0.7.*;platform_system!='Windows'",
99+
"coveralls==4.0.*",
100+
"pytest-cov==6.2.*",
101+
"coverage==7.10.*",
102+
"hypothesis==6.136.*",
103+
"parameterized==0.9.*",
103104
]
104105
dev = [
105106
{include-group = "docs"},

0 commit comments

Comments
 (0)