mirror of
https://github.com/libSDL2pp/libSDL2pp.git
synced 2025-09-09 15:28:29 -04:00
Add test case for RWops+Font (issue #94)
This commit is contained in:
parent
d8c5cfb56e
commit
aef47fbfeb
@ -1,8 +1,9 @@
|
|||||||
#include <SDL_main.h>
|
#include <SDL_main.h>
|
||||||
|
|
||||||
#include <SDL2pp/SDLTTF.hh>
|
|
||||||
#include <SDL2pp/Font.hh>
|
|
||||||
#include <SDL2pp/Exception.hh>
|
#include <SDL2pp/Exception.hh>
|
||||||
|
#include <SDL2pp/Font.hh>
|
||||||
|
#include <SDL2pp/RWops.hh>
|
||||||
|
#include <SDL2pp/SDLTTF.hh>
|
||||||
|
|
||||||
#include "testing.h"
|
#include "testing.h"
|
||||||
#include "movetest.hh"
|
#include "movetest.hh"
|
||||||
@ -13,6 +14,14 @@ BEGIN_TEST(int, char*[])
|
|||||||
SDLTTF ttf;
|
SDLTTF ttf;
|
||||||
Font font(TESTDATA_DIR "/Vera.ttf", 30);
|
Font font(TESTDATA_DIR "/Vera.ttf", 30);
|
||||||
|
|
||||||
|
// RWops
|
||||||
|
{
|
||||||
|
auto rwops = RWops::FromFile(TESTDATA_DIR "/Vera.ttf");
|
||||||
|
Font font_by_rw(rwops, 30);
|
||||||
|
|
||||||
|
EXPECT_TRUE(font_by_rw.Get());
|
||||||
|
}
|
||||||
|
|
||||||
MOVE_TEST(Font, font, Get, nullptr);
|
MOVE_TEST(Font, font, Get, nullptr);
|
||||||
|
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user