Skip to content

Commit e54aaa0

Browse files
Exercise default_sycl_platform on Linux only
It is not yet supported on Windows.
1 parent b40d357 commit e54aaa0

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

dpctl/tests/test_sycl_platform.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@
1717
"""Defines unit test cases for the SyclPlatform class.
1818
"""
1919

20+
import sys
21+
2022
import pytest
2123
from helper import has_sycl_platforms
2224

@@ -88,12 +90,16 @@ def check_repr(platform):
8890

8991

9092
def check_default_context(platform):
93+
if "linux" not in sys.platform:
94+
return
9195
r = platform.default_context
9296
assert type(r) is dpctl.SyclContext
9397

9498

9599
def check_equal_and_hash(platform):
96100
assert platform == platform
101+
if "linux" not in sys.platform:
102+
return
97103
default_ctx = platform.default_context
98104
for d in default_ctx.get_devices():
99105
assert platform == d.sycl_platform

0 commit comments

Comments
 (0)