diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-27 12:29:45 +0100 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-12-27 12:29:45 +0100 |
| commit | c81154c470cec39f092c6ff094cd45d3f27410f3 (patch) | |
| tree | ab540cae3f84d7f8775f70e252bc96a766ef4768 /test/allocator_op.test.cpp | |
| parent | f69ab8b1fcc0e1cca1c1dff96e204440f1f4f7f3 (diff) | |
test: Use correct macros for option unit tests.
test: allocator_op is now doing the full range check.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'test/allocator_op.test.cpp')
| -rw-r--r-- | test/allocator_op.test.cpp | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/test/allocator_op.test.cpp b/test/allocator_op.test.cpp index 33546de..5979c7d 100644 --- a/test/allocator_op.test.cpp +++ b/test/allocator_op.test.cpp @@ -15,6 +15,9 @@ BOOST_AUTO_TEST_CASE(allocator_should_succeed) auto ptr = ocl::allocator<int>{}.construct_array<10>(); int* arr = ptr.get(); BOOST_TEST(arr != nullptr); - *arr = 10; - BOOST_TEST(*arr == 10); + for (auto i{0ul}; i < 10; ++i) + { + *(arr + i) = 10; + BOOST_TEST(*(arr + i) == 10); + } } |
