From e8aaad290a480ae7a16779bc694d9cb1fd1060f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B3zef=20Kucia?= Date: Tue, 9 Jan 2018 15:10:04 +0100 Subject: [PATCH] dxgi/tests: Skip tests if DXGI_ERROR_NOT_CURRENTLY_AVAILABLE is returned. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Józef Kucia Signed-off-by: Henri Verbeet Signed-off-by: Alexandre Julliard --- dlls/dxgi/tests/device.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/dlls/dxgi/tests/device.c b/dlls/dxgi/tests/device.c index 2bc0ff4071b..a102ed89aa6 100644 --- a/dlls/dxgi/tests/device.c +++ b/dlls/dxgi/tests/device.c @@ -1494,7 +1494,13 @@ static void test_swapchain_fullscreen_state(IDXGISwapChain *swapchain, ok(SUCCEEDED(hr), "GetContainingOutput failed, hr %#x.\n", hr); hr = IDXGISwapChain_SetFullscreenState(swapchain, TRUE, NULL); - ok(SUCCEEDED(hr), "SetFullscreenState failed, hr %#x.\n", hr); + ok(hr == S_OK || hr == DXGI_ERROR_NOT_CURRENTLY_AVAILABLE, "Got unexpected hr %#x.\n", hr); + if (FAILED(hr)) + { + skip("Could not change fullscreen state.\n"); + IDXGIOutput_Release(expected_state.target); + return; + } check_swapchain_fullscreen_state(swapchain, &expected_state); hr = IDXGISwapChain_SetFullscreenState(swapchain, TRUE, NULL);