diff options
Diffstat (limited to 'offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp')
-rw-r--r-- | offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp b/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp index acda479..cb77acf 100644 --- a/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp +++ b/offload/unittests/OffloadAPI/kernel/olLaunchKernel.cpp @@ -223,6 +223,14 @@ TEST_P(olLaunchKernelGlobalTest, Success) { ASSERT_SUCCESS(olMemFree(Mem)); } +TEST_P(olLaunchKernelGlobalTest, InvalidNotAKernel) { + ol_symbol_handle_t Global = nullptr; + ASSERT_SUCCESS(olGetGlobalVariable(Program, "global", &Global)); + ASSERT_ERROR( + OL_ERRC_SYMBOL_KIND, + olLaunchKernel(Queue, Device, Global, nullptr, 0, &LaunchArgs, nullptr)); +} + TEST_P(olLaunchKernelGlobalCtorTest, Success) { void *Mem; ASSERT_SUCCESS(olMemAlloc(Device, OL_ALLOC_TYPE_MANAGED, |