mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-03 23:03:02 +08:00
fix: Fail device init if kernel debugging is misconfigured
Also print error to stderr Related-to: GSD-10780 Signed-off-by: Brandon Yates <brandon.yates@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
75119f1887
commit
c122bc51f9
@@ -2094,7 +2094,7 @@ TEST_F(DeviceTests, GivenDebuggingEnabledWhenDeviceIsInitializedThenL0DebuggerIs
|
||||
EXPECT_NE(nullptr, device->getL0Debugger());
|
||||
}
|
||||
|
||||
TEST_F(DeviceTests, givenDebuggerRequestedByUserAndNotAvailableWhenDeviceIsInitializedThenErrorIsPrintedButNotReturned) {
|
||||
TEST_F(DeviceTests, givenDebuggerRequestedByUserAndNotAvailableWhenDeviceIsInitializedThenDeviceIsNullAndErrorIsPrinted) {
|
||||
extern bool forceCreateNullptrDebugger;
|
||||
|
||||
VariableBackup backupForceCreateNullptrDebugger{&forceCreateNullptrDebugger, true};
|
||||
@@ -2109,7 +2109,7 @@ TEST_F(DeviceTests, givenDebuggerRequestedByUserAndNotAvailableWhenDeviceIsIniti
|
||||
auto output = testing::internal::GetCapturedStderr();
|
||||
|
||||
EXPECT_EQ(std::string("Debug mode is not enabled in the system.\n"), output);
|
||||
EXPECT_EQ(nullptr, device->getL0Debugger());
|
||||
EXPECT_EQ(nullptr, device);
|
||||
}
|
||||
|
||||
TEST_F(DeviceTests, givenDebuggerRequestedByUserWhenDeviceWithSubDevicesCreatedThenInitializeDebuggerOncePerRootDevice) {
|
||||
|
||||
Reference in New Issue
Block a user