mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-05 09:09:04 +08:00
Cleaned up files: level_zero/tools/test/unit_tests/sources/sysman/windows/mock_sysman_fixture.h shared/test/common/os_interface/windows/wddm_fixture.h shared/test/unit_test/command_stream/compute_mode_tests.h shared/test/unit_test/encoders/walker_partition_fixture_xehp_and_later.h shared/test/unit_test/fixtures/preemption_fixture.h shared/test/unit_test/helpers/blit_commands_helper_tests.inl shared/test/unit_test/helpers/simd_helper_tests.inl Related-To: NEO-5548 Signed-off-by: Warchulski, Jaroslaw <jaroslaw.warchulski@intel.com>
33 lines
1.2 KiB
C++
33 lines
1.2 KiB
C++
/*
|
|
* Copyright (C) 2018-2023 Intel Corporation
|
|
*
|
|
* SPDX-License-Identifier: MIT
|
|
*
|
|
*/
|
|
|
|
#include "shared/source/gen9/hw_cmds_base.h"
|
|
#include "shared/test/common/test_macros/header/per_product_test_definitions.h"
|
|
#include "shared/test/common/test_macros/test.h"
|
|
|
|
#include "opencl/test/unit_test/fixtures/image_fixture.h"
|
|
#include "opencl/test/unit_test/mocks/mock_context.h"
|
|
|
|
using namespace NEO;
|
|
|
|
typedef ::testing::Test gen9ImageTests;
|
|
|
|
GEN9TEST_F(gen9ImageTests, appendSurfaceSWhenAppendingSurfaceStateParamsThenSurfaceStateDoesNotChangetateParamsDoesNothing) {
|
|
typedef typename FamilyType::RENDER_SURFACE_STATE RENDER_SURFACE_STATE;
|
|
MockContext context;
|
|
auto image = std::unique_ptr<Image>(ImageHelper<Image1dDefaults>::create(&context));
|
|
auto surfaceStateBefore = FamilyType::cmdInitRenderSurfaceState;
|
|
auto surfaceStateAfter = FamilyType::cmdInitRenderSurfaceState;
|
|
auto imageHw = static_cast<ImageHw<FamilyType> *>(image.get());
|
|
|
|
EXPECT_EQ(0, memcmp(&surfaceStateBefore, &surfaceStateAfter, sizeof(RENDER_SURFACE_STATE)));
|
|
|
|
imageHw->appendSurfaceStateParams(&surfaceStateAfter, context.getDevice(0)->getRootDeviceIndex(), false);
|
|
|
|
EXPECT_EQ(0, memcmp(&surfaceStateBefore, &surfaceStateAfter, sizeof(RENDER_SURFACE_STATE)));
|
|
}
|