#pragma once #include #include #include "XCEngine/RHI/D3D12/D3D12Device.h" #include "XCEngine/RHI/D3D12/D3D12CommandQueue.h" #include "XCEngine/RHI/D3D12/D3D12CommandAllocator.h" #include "XCEngine/RHI/D3D12/D3D12CommandList.h" #include "XCEngine/RHI/D3D12/D3D12Fence.h" namespace XCEngine { namespace RHI { class D3D12TestFixture : public ::testing::Test { protected: static void SetUpTestSuite(); static void TearDownTestSuite(); void SetUp() override; void TearDown() override; D3D12Device* GetDevice() { return m_device.get(); } D3D12CommandQueue* GetCommandQueue() { return m_commandQueue.get(); } D3D12CommandList* GetCommandList() { return m_commandList.get(); } D3D12CommandAllocator* GetCommandAllocator() { return m_commandAllocator.get(); } void WaitForGPU(); private: std::unique_ptr m_device; std::unique_ptr m_commandQueue; std::unique_ptr m_commandAllocator; std::unique_ptr m_commandList; }; } // namespace RHI } // namespace XCEngine