1
0
mirror of https://github.com/rwengine/openrw.git synced 2024-11-09 20:32:43 +01:00
openrw/tests/test_loaderdff.cpp
2014-06-04 06:02:41 +01:00

27 lines
531 B
C++

#include <boost/test/unit_test.hpp>
#include "test_globals.hpp"
#include <render/Model.hpp>
BOOST_AUTO_TEST_SUITE(LoaderDFFTests)
BOOST_AUTO_TEST_CASE(test_open_dff)
{
LoaderIMG loader;
BOOST_REQUIRE( loader.load(Global::getGamePath() + "/models/gta3") );
auto d = loader.loadToMemory("landstal.dff");
LoaderDFF dffloader;
Model* m = dffloader.loadFromMemory(d, &Global::get().e->gameData);
BOOST_REQUIRE( m != nullptr );
BOOST_CHECK( m->frames.size() > 0 );
delete d;
delete m;
}
BOOST_AUTO_TEST_SUITE_END()