X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e3527f7bc58048611c213a801b20c3d03664c225..ce00f59b5b169752d2f05ce3bb1a88ddc1b38b4c:/tests/misc/settings.cpp diff --git a/tests/misc/settings.cpp b/tests/misc/settings.cpp index c87e8310cc..09174d2888 100644 --- a/tests/misc/settings.cpp +++ b/tests/misc/settings.cpp @@ -19,6 +19,8 @@ #include "wx/settings.h" #include "wx/fontenum.h" +#include "wx/brush.h" +#include "wx/pen.h" // ---------------------------------------------------------------------------- // test class @@ -104,7 +106,7 @@ void SettingsTestCase::GlobalColours() void SettingsTestCase::GlobalFonts() { - wxFont font[] = + const wxFont font[] = { *wxNORMAL_FONT, *wxSMALL_FONT, @@ -113,8 +115,18 @@ void SettingsTestCase::GlobalFonts() }; for (unsigned int i=0; i < WXSIZEOF(font); i++) - CPPUNIT_ASSERT( font[i].IsOk() && - wxFontEnumerator::IsValidFacename(font[i].GetFaceName()) ); + { + CPPUNIT_ASSERT( font[i].IsOk() ); + + const wxString facename = font[i].GetFaceName(); + if ( !facename.empty() ) + { + WX_ASSERT_MESSAGE( + ("font #%u: facename \"%s\" is invalid", i, facename), + wxFontEnumerator::IsValidFacename(facename) + ); + } + } } void SettingsTestCase::GlobalBrushes()