Commit a76e6b11 authored by Francois Gouget's avatar Francois Gouget Committed by Alexandre Julliard

d3d8/tests: Warn that tests were skipped if we could not load d3d8.dll.

But report a failed test if a mandatory function is missing from it.
parent 354b9e7a
...@@ -107,7 +107,11 @@ START_TEST(d3d8_main) ...@@ -107,7 +107,11 @@ START_TEST(d3d8_main)
{ {
HMODULE d3d8_handle = LoadLibraryA( "d3d8.dll" ); HMODULE d3d8_handle = LoadLibraryA( "d3d8.dll" );
if (!d3d8_handle) if (!d3d8_handle)
{
skip("Could not load d3d8.dll\n");
return; return;
}
ValidateVertexShader = (void*)GetProcAddress (d3d8_handle, "ValidateVertexShader" ); ValidateVertexShader = (void*)GetProcAddress (d3d8_handle, "ValidateVertexShader" );
ValidatePixelShader = (void*)GetProcAddress (d3d8_handle, "ValidatePixelShader" ); ValidatePixelShader = (void*)GetProcAddress (d3d8_handle, "ValidatePixelShader" );
test_ValidateVertexShader(); test_ValidateVertexShader();
......
...@@ -763,8 +763,14 @@ static void test_display_modes(void) ...@@ -763,8 +763,14 @@ static void test_display_modes(void)
START_TEST(device) START_TEST(device)
{ {
HMODULE d3d8_handle = LoadLibraryA( "d3d8.dll" ); HMODULE d3d8_handle = LoadLibraryA( "d3d8.dll" );
if (!d3d8_handle)
{
skip("Could not load d3d8.dll\n");
return;
}
pDirect3DCreate8 = (void *)GetProcAddress( d3d8_handle, "Direct3DCreate8" ); pDirect3DCreate8 = (void *)GetProcAddress( d3d8_handle, "Direct3DCreate8" );
ok(pDirect3DCreate8 != NULL, "Failed to get address of Direct3DCreate8\n");
if (pDirect3DCreate8) if (pDirect3DCreate8)
{ {
test_display_modes(); test_display_modes();
......
...@@ -129,7 +129,7 @@ START_TEST(surface) ...@@ -129,7 +129,7 @@ START_TEST(surface)
d3d8_handle = LoadLibraryA("d3d8.dll"); d3d8_handle = LoadLibraryA("d3d8.dll");
if (!d3d8_handle) if (!d3d8_handle)
{ {
trace("Could not load d3d8.dll, skipping tests\n"); skip("Could not load d3d8.dll\n");
return; return;
} }
......
...@@ -110,7 +110,7 @@ START_TEST(texture) ...@@ -110,7 +110,7 @@ START_TEST(texture)
d3d8_handle = LoadLibraryA("d3d8.dll"); d3d8_handle = LoadLibraryA("d3d8.dll");
if (!d3d8_handle) if (!d3d8_handle)
{ {
trace("Could not load d3d8.dll, skipping tests\n"); skip("Could not load d3d8.dll\n");
return; return;
} }
......
...@@ -129,7 +129,7 @@ START_TEST(volume) ...@@ -129,7 +129,7 @@ START_TEST(volume)
d3d8_handle = LoadLibraryA("d3d8.dll"); d3d8_handle = LoadLibraryA("d3d8.dll");
if (!d3d8_handle) if (!d3d8_handle)
{ {
trace("Could not load d3d8.dll, skipping tests\n"); skip("Could not load d3d8.dll\n");
return; return;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment