Skip to content

Commit

Permalink
fixed test_opencl mypy issues
Browse files Browse the repository at this point in the history
  • Loading branch information
sakchal committed May 2, 2024
1 parent f84366d commit 4a505dc
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions tests/test_opencl.py
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
import arrayfire_wrapper.lib.interface_functions.opencl as cl


def test_get_context_type():
def test_get_context_type() -> None:
assert isinstance(cl.get_context(), int)


def test_get_queue_type():
def test_get_queue_type() -> None:
assert isinstance(cl.get_queue(), int)


def test_get_device_id():
def test_get_device_id() -> None:
assert isinstance(cl.get_device_id(), int)


def test_set_device_id():
def test_set_device_id() -> None:
cl.set_device_id(0)
assert cl.get_device_id() == 0


def test_get_device_type():
def test_get_device_type() -> None:
assert cl.get_device_type() == cl.DeviceType.GPU # change according to device


def test_get_platform():
def test_get_platform() -> None:
assert cl.get_platform() == cl.PlatformType.INTEL # change according to platform

0 comments on commit 4a505dc

Please sign in to comment.