different improvements
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
|
||||
#include <catch2/catch_all.hpp>
|
||||
#include "Base/Logger.hpp"
|
||||
#include "Host/SystemInfo.hpp"
|
||||
#include "Host/SystemFontResolver.hpp"
|
||||
#include <filesystem>
|
||||
|
||||
#include "Scene/Text/FontAtlasFactory.hpp"
|
||||
@@ -18,16 +18,16 @@ TEST_CASE("Search system fonts")
|
||||
Logger::SetupLogger("", "tests.log");
|
||||
|
||||
// assume these fonts are present since they are default
|
||||
std::filesystem::path path = SystemInfo::GetSystemFontPath("Arial");
|
||||
std::filesystem::path path = SystemFontResolver::GetSystemFontPath("Arial");
|
||||
REQUIRE(path.filename() == "arial.ttf");
|
||||
|
||||
// assume these fonts are present since they are default
|
||||
path = SystemInfo::GetSystemFontPath("Times New Roman");
|
||||
path = SystemFontResolver::GetSystemFontPath("Times New Roman");
|
||||
REQUIRE(path.filename() == "times.ttf");
|
||||
|
||||
path = SystemInfo::GetSystemFontPath("Arial Bold Italic");
|
||||
path = SystemFontResolver::GetSystemFontPath("Arial Bold Italic");
|
||||
REQUIRE(path.filename() == "arialbi.ttf");
|
||||
|
||||
path = SystemInfo::GetSystemFontPath("NON-EXISTING Font");
|
||||
path = SystemFontResolver::GetSystemFontPath("NON-EXISTING Font");
|
||||
REQUIRE(path.empty());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user