mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 06:49:52 +08:00
Add cl_khr_device_uuid to extension list
Related-To: NEO-5681 Signed-off-by: Baj, Tomasz <tomasz.baj@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
d5b2f03dc4
commit
b450d3c20b
13
shared/test/unit_test/device/linux/CMakeLists.txt
Normal file
13
shared/test/unit_test/device/linux/CMakeLists.txt
Normal file
@@ -0,0 +1,13 @@
|
||||
#
|
||||
# Copyright (C) 2022 Intel Corporation
|
||||
#
|
||||
# SPDX-License-Identifier: MIT
|
||||
#
|
||||
|
||||
if(UNIX)
|
||||
target_sources(${TARGET_NAME} PRIVATE
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/CMakeLists.txt
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/neo_device_linux_tests.cpp
|
||||
)
|
||||
endif()
|
||||
add_subdirectories()
|
||||
@@ -0,0 +1,41 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#include "shared/source/device/device.h"
|
||||
#include "shared/test/common/fixtures/device_fixture.h"
|
||||
#include "shared/test/common/helpers/debug_manager_state_restore.h"
|
||||
#include "shared/test/common/test_macros/test.h"
|
||||
|
||||
using DeviceTest = Test<DeviceFixture>;
|
||||
|
||||
TEST_F(DeviceTest, GivenDeviceWhenGetAdapterLuidThenLuidIsNotSet) {
|
||||
std::array<uint8_t, HwInfoConfig::luidSize> luid, expectedLuid;
|
||||
expectedLuid.fill(-1);
|
||||
luid = expectedLuid;
|
||||
pDevice->getAdapterLuid(luid);
|
||||
|
||||
EXPECT_EQ(expectedLuid, luid);
|
||||
}
|
||||
|
||||
TEST_F(DeviceTest, GivenDeviceWhenVerifyAdapterLuidThenFalseIsReturned) {
|
||||
EXPECT_FALSE(pDevice->verifyAdapterLuid());
|
||||
}
|
||||
|
||||
TEST_F(DeviceTest, GivenDeviceWhenGetAdapterMaskThenMaskIsNotSet) {
|
||||
uint32_t nodeMask = 0x1234u;
|
||||
pDevice->getAdapterMask(nodeMask);
|
||||
|
||||
EXPECT_EQ(nodeMask, 0x1234u);
|
||||
}
|
||||
|
||||
TEST_F(DeviceTest, GivenCallBaseVerifyAdapterLuidWhenGetAdapterMaskThenMaskIsSet) {
|
||||
uint32_t nodeMask = 0x1234u;
|
||||
pDevice->callBaseVerifyAdapterLuid = false;
|
||||
pDevice->getAdapterMask(nodeMask);
|
||||
|
||||
EXPECT_EQ(nodeMask, 1u);
|
||||
}
|
||||
Reference in New Issue
Block a user