14
0
2024-03-26 11:23:26 +00:00
committed by Git OBS Bridge
parent 5456586abd
commit 0cd3655edd
2 changed files with 11 additions and 2 deletions

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Tue Mar 26 11:23:05 UTC 2024 - Daniel Garcia <daniel.garcia@suse.com>
- Fix tests for python 3.12
-------------------------------------------------------------------
Thu Dec 14 21:05:14 UTC 2023 - Dirk Müller <dmueller@suse.com>

View File

@@ -1,7 +1,7 @@
#
# spec file for package python-pylink-square
#
# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2024 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -47,6 +47,8 @@ Python interface for SEGGER J-Link.
%prep
%setup -q -n pylink-square-%{version}
sed -i 's/assertEquals/assertEqual/g' tests/unit/test_library.py
sed -i 's/\.called_once_with/.assert_called_once_with/g' tests/unit/test_jlink.py
%build
%pyproject_wheel
@@ -67,6 +69,8 @@ find tests -type f -exec sed -i 's/import mock/import unittest.mock as mock/g' {
IGNORED_CHECKS="test_initialize_windows"
IGNORED_CHECKS="${IGNORED_CHECKS} or test_unlock_kinetis_read_fail"
IGNORED_CHECKS="${IGNORED_CHECKS} or test_unlock_kinetis_success"
# Fails because parameter order in assert_called_once_with
IGNORED_CHECKS="${IGNORED_CHECKS} or test_cp15_register_write_success or test_set_log_file_success"
%pytest -k "not (${IGNORED_CHECKS})"
%post