diff --git a/opencl/test/unit_test/aub_tests/gen12lp/aub_mem_dump_tests_gen12lp.cpp b/opencl/test/unit_test/aub_tests/gen12lp/aub_mem_dump_tests_gen12lp.cpp index 35faa3327a..488e72c251 100644 --- a/opencl/test/unit_test/aub_tests/gen12lp/aub_mem_dump_tests_gen12lp.cpp +++ b/opencl/test/unit_test/aub_tests/gen12lp/aub_mem_dump_tests_gen12lp.cpp @@ -1,10 +1,13 @@ /* - * Copyright (C) 2019-2023 Intel Corporation + * Copyright (C) 2019-2024 Intel Corporation * * SPDX-License-Identifier: MIT * */ +#include "shared/source/command_stream/aub_command_stream_receiver_hw.h" +#include "shared/test/common/helpers/debug_manager_state_restore.h" +#include "shared/test/common/helpers/ult_hw_config.h" #include "shared/test/common/mocks/mock_device.h" #include "opencl/test/unit_test/aub_tests/command_stream/aub_mem_dump_tests.h" @@ -18,4 +21,18 @@ GEN12LPTEST_F(Gen12LPAubMemDumpTests, GivenCcsThenExpectationsAreMet) { setupAUB(pDevice, aub_stream::ENGINE_CCS); } +GEN12LPTEST_F(Gen12LPAubMemDumpTests, whenAubCsrIsCreatedThenCreateHardwareContext) { + DebugManagerStateRestore restore; + VariableBackup backup(&ultHwConfig); + ultHwConfig.useHwCsr = true; + + std::unique_ptr device(MockDevice::createWithNewExecutionEnvironment(defaultHwInfo.get())); + + auto &baseCsr = device->getGpgpuCommandStreamReceiver(); + auto &aubCsr = static_cast &>(baseCsr); + + EXPECT_NE(nullptr, aubCsr.hardwareContextController.get()); + EXPECT_NE(0u, aubCsr.hardwareContextController->hardwareContexts.size()); +} + } // namespace NEO