Skip to content

Commit d6de7f4

Browse files
committed
Fix tests to iOS
1 parent afdbf74 commit d6de7f4

File tree

6 files changed

+15
-1
lines changed

6 files changed

+15
-1
lines changed

.github/workflows/deploy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ jobs:
3838
CIBW_ARCHS_IOS: "arm64_iphoneos arm64_iphonesimulator x86_64_iphonesimulator"
3939
CIBW_BUILD: "cp313-* cp314-*"
4040
CIBW_TEST_REQUIRES: "pytest"
41-
CIBW_TEST_COMMAND: python -m pytest tests"
41+
CIBW_TEST_COMMAND: python -m pytest tests
4242
with:
4343
output-dir: dist
4444

tests/test_carray.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
from pyobjus.dylib_manager import load_dylib
55
import ctypes
66
import pytest
7+
import sys
78

89
num_list = [0, 2, 1, 5, 4, 3, 6, 7, 8, 9]
910
char_list = ["a", "b", "c", "d", "e", "f", "g", "h", "i", "j"]
@@ -27,6 +28,7 @@
2728

2829
_instance = None
2930

31+
@pytest.skipif(sys.platform != "darwin", reason="Only for MacOS, as it needs test dylib")
3032
class CArrayTest(unittest.TestCase):
3133

3234
def setUp(self):

tests/test_dereference.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,12 @@
22
from pyobjus import autoclass, dereference, ObjcInt
33
from pyobjus.dylib_manager import load_dylib
44
from pyobjus.objc_py_types import NSRange
5+
import pytest
6+
import sys
57

68
Car = car = None
79

10+
@pytest.skipif(sys.platform != "darwin", reason="Only for MacOS, as it needs test dylib")
811
class DereferenceTest(unittest.TestCase):
912

1013
def setUp(self):

tests/test_properties.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
import unittest
22
from pyobjus import autoclass, dereference
33
from pyobjus.dylib_manager import load_dylib
4+
import pytest
5+
import sys
46

57
Car = None
68

9+
@pytest.skipif(sys.platform != "darwin", reason="Only for MacOS, as it needs test dylib")
710
class ObjcPropertyTest(unittest.TestCase):
811

912
def setUp(self):

tests/test_union.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
import unittest
22
from pyobjus import autoclass, dereference, objc_py_types as opy
33
from pyobjus.dylib_manager import load_dylib
4+
import pytest
5+
import sys
46

57
Car = None
68

9+
@pytest.skipif(sys.platform != "darwin", reason="Only for MacOS, as it needs test dylib")
710
class Union(unittest.TestCase):
811

912
def setUp(self):

tests/test_unknown_types.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,12 @@
11
import unittest
22
from pyobjus import autoclass, selector
33
from pyobjus.dylib_manager import load_dylib
4+
import pytest
5+
import sys
46

57
Car = car = None
68

9+
@pytest.skipif(sys.platform != "darwin", reason="Only for MacOS, as it needs test dylib")
710
class UnknownTypesTest(unittest.TestCase):
811

912
def setUp(self):

0 commit comments

Comments
 (0)