upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/test/device_proxy_test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'runtime/test/device_proxy_test.cpp')
-rw-r--r--runtime/test/device_proxy_test.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/runtime/test/device_proxy_test.cpp b/runtime/test/device_proxy_test.cpp
index 748cc2e99..fe17d2833 100644
--- a/runtime/test/device_proxy_test.cpp
+++ b/runtime/test/device_proxy_test.cpp
@@ -115,11 +115,16 @@ int main() {
115 check(SUCCEEDED(hr) && factory, "DXGI factory created"); 115 check(SUCCEEDED(hr) && factory, "DXGI factory created");
116 ComPtr<IDXGIAdapter> warp; 116 ComPtr<IDXGIAdapter> warp;
117 if (factory) hr = factory->EnumWarpAdapter(IID_PPV_ARGS(warp.GetAddressOf())); 117 if (factory) hr = factory->EnumWarpAdapter(IID_PPV_ARGS(warp.GetAddressOf()));
118 check(SUCCEEDED(hr) && warp, "WARP adapter enumerated"); 118 if (!factory) {
119 if (!warp) { 119 std::printf("device_proxy_test: FAILED (no DXGI factory)\n");
120 std::printf("device_proxy_test: FAILED (no WARP)\n");
121 return 1; 120 return 1;
122 } 121 }
122 if (!warp) {
123 // Windows always has WARP; Wine doesn't. CTest reads exit code 77 as a skip (SKIP_RETURN_CODE).
124 std::printf("SKIP device_proxy_test: no WARP adapter (0x%08lX)\n", static_cast<unsigned long>(hr));
125 return 77;
126 }
127 check(true, "WARP adapter enumerated");
123 128
124 auto create_device = reinterpret_cast<XboxCreateDeviceFn>( 129 auto create_device = reinterpret_cast<XboxCreateDeviceFn>(
125 rt::shims::find("d3d12_xs.dll", "D3D12XboxCreateDevice")); 130 rt::shims::find("d3d12_xs.dll", "D3D12XboxCreateDevice"));