[PATCH] d3d11/test: Test for ID3D11InfoQueue interface
Alistair Leslie-Hughes
leslie_alistair at hotmail.com
Wed May 11 01:15:22 CDT 2016
---
dlls/d3d11/tests/d3d11.c | 14 +++++++++++---
1 file changed, 11 insertions(+), 3 deletions(-)
diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c
index 03b6113..e642b33 100644
--- a/dlls/d3d11/tests/d3d11.c
+++ b/dlls/d3d11/tests/d3d11.c
@@ -827,7 +827,7 @@ static void test_create_device(void)
DestroyWindow(window);
}
-static void test_device_interfaces(void)
+static void test_device_interfaces(int flags)
{
IDXGIAdapter *dxgi_adapter;
IDXGIDevice *dxgi_device;
@@ -842,7 +842,7 @@ static void test_device_interfaces(void)
struct device_desc device_desc;
device_desc.feature_level = &d3d11_feature_levels[i];
- device_desc.flags = 0;
+ device_desc.flags = flags;
if (!(device = create_device(&device_desc)))
{
skip("Failed to create device for feature level %#x.\n", d3d11_feature_levels[i]);
@@ -882,6 +882,13 @@ static void test_device_interfaces(void)
"Device should implement ID3D10Multithread interface, hr %#x.\n", hr);
if (SUCCEEDED(hr)) IUnknown_Release(iface);
+ hr = ID3D11Device_QueryInterface(device, &IID_ID3D11InfoQueue, (void **)&iface);
+ if (flags & D3D11_CREATE_DEVICE_DEBUG)
+ todo_wine ok(hr == S_OK, "Device should implement ID3D11InfoQueue interface, hr %#x.\n", hr);
+ else
+ ok(hr == E_NOINTERFACE, "Found ID3D11InfoQueue interface in non-debug mode, hr %#x.\n", hr);
+ if (SUCCEEDED(hr)) IUnknown_Release(iface);
+
hr = ID3D11Device_QueryInterface(device, &IID_ID3D10Device, (void **)&iface);
todo_wine ok(hr == E_NOINTERFACE, "Device should not implement ID3D10Device interface, hr %#x.\n", hr);
if (SUCCEEDED(hr)) IUnknown_Release(iface);
@@ -6795,7 +6802,8 @@ static void test_getdc(void)
START_TEST(d3d11)
{
test_create_device();
- test_device_interfaces();
+ test_device_interfaces(0);
+ test_device_interfaces(D3D11_CREATE_DEVICE_DEBUG);
test_get_immediate_context();
test_create_texture2d();
test_texture2d_interfaces();
--
2.8.1
More information about the wine-patches
mailing list