Signed-off-by: Alex Henrie alexhenrie24@gmail.com --- This should fix the test failures on Debian. --- dlls/gdiplus/tests/font.c | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/dlls/gdiplus/tests/font.c b/dlls/gdiplus/tests/font.c index 961d8459cb..bbddcce345 100644 --- a/dlls/gdiplus/tests/font.c +++ b/dlls/gdiplus/tests/font.c @@ -430,28 +430,34 @@ static void test_getgenerics (void) int missingfonts = 0;
stat = GdipGetGenericFontFamilySansSerif(&family); - expect (Ok, stat); if (stat == FontFamilyNotFound) missingfonts = 1; else + { + expect(Ok, stat); check_family("Sans Serif", family, sansname); + }
stat = GdipGetGenericFontFamilySerif(&family); - expect (Ok, stat); if (stat == FontFamilyNotFound) missingfonts = 1; else + { + expect(Ok, stat); check_family("Serif", family, serifname); + }
stat = GdipGetGenericFontFamilyMonospace(&family); - expect (Ok, stat); if (stat == FontFamilyNotFound) missingfonts = 1; else + { + expect(Ok, stat); check_family("Monospace", family, mononame); + }
- if (missingfonts && strcmp(winetest_platform, "wine") == 0) - trace("You may need to install either the Microsoft Web Fonts or the Liberation Fonts\n"); + if (missingfonts) + skip("You may need to install either the Microsoft Web Fonts or the Liberation Fonts\n");
/* Check that the family names are all different */ ok(lstrcmpiW(sansname, serifname) != 0, "Sans Serif and Serif families should be different: %s\n", wine_dbgstr_w(sansname));
Apologies for taking so long to get to this. I'm still dealing with health problems.
I'm concerned that this will make the tests succeed with missing fonts on Windows, and the various name variables will be used uninitialized (which would've happened before, but only when the tests were failing). Maybe a todo_wine ok(0) and a return in the missing fonts case would solve that.
It'd be nice to hear from the winetest maintainer about this case. In other cases, we've made the decision that the tests should fail if an API breaks because optional dependencies are missing. I don't know that we officially have a dependency on those fonts, but API's are breaking because they are missing.
On Thu, Oct 4, 2018 at 10:02 AM Vincent Povirk vincent@codeweavers.com wrote:
I'm concerned that this will make the tests succeed with missing fonts on Windows, and the various name variables will be used uninitialized (which would've happened before, but only when the tests were failing). Maybe a todo_wine ok(0) and a return in the missing fonts case would solve that.
It'd be nice to hear from the winetest maintainer about this case. In other cases, we've made the decision that the tests should fail if an API breaks because optional dependencies are missing. I don't know that we officially have a dependency on those fonts, but API's are breaking because they are missing.
That makes sense. It sounds like the right solution is to install these fonts on our Debian testbot VMs.
-Alex
On Thu, 4 Oct 2018, Vincent Povirk wrote: [...]
It'd be nice to hear from the winetest maintainer about this case. In other cases, we've made the decision that the tests should fail if an API breaks because optional dependencies are missing. I don't know that we officially have a dependency on those fonts, but API's are breaking because they are missing.
Given that no Windows system would be missing those fonts I think it's reasonable for the test to depend on them and have failures if they are missing. So I updated the Wine VM configuration and the TestBot VMs Wiki page.
https://wiki.winehq.org/Wine_TestBot_VMs#Unix_configuration
On Mon, Oct 15, 2018 at 4:26 PM Francois Gouget fgouget@codeweavers.com wrote:
On Thu, 4 Oct 2018, Vincent Povirk wrote: [...]
It'd be nice to hear from the winetest maintainer about this case. In other cases, we've made the decision that the tests should fail if an API breaks because optional dependencies are missing. I don't know that we officially have a dependency on those fonts, but API's are breaking because they are missing.
Given that no Windows system would be missing those fonts I think it's reasonable for the test to depend on them and have failures if they are missing. So I updated the Wine VM configuration and the TestBot VMs Wiki page.
Thanks Francois!
-Alex