Refactor 3D import unit test
parent
69284bdef9
commit
461f9923a7
|
@ -42,23 +42,16 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "UnitTestPCH.h"
|
#include "UnitTestPCH.h"
|
||||||
#include "SceneDiffer.h"
|
|
||||||
#include "AbstractImportExportBase.h"
|
|
||||||
|
|
||||||
#include <assimp/Importer.hpp>
|
#include <assimp/Importer.hpp>
|
||||||
#include <assimp/postprocess.h>
|
#include <assimp/postprocess.h>
|
||||||
|
|
||||||
|
|
||||||
using namespace Assimp;
|
using namespace Assimp;
|
||||||
|
|
||||||
class ut3DImportExport : public AbstractImportExportBase {
|
|
||||||
public:
|
|
||||||
virtual bool importerTest() {
|
|
||||||
Assimp::Importer importer;
|
|
||||||
const aiScene *scene = importer.ReadFile( ASSIMP_TEST_MODELS_DIR "/3D/box_a.3d", aiProcess_ValidateDataStructure );
|
|
||||||
return nullptr != scene;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
TEST_F( ut3DImportExport, import3DFromFileTest ) {
|
TEST(ut3DImportExport, importBoxA) {
|
||||||
EXPECT_TRUE( importerTest() );
|
Assimp::Importer importer;
|
||||||
|
const aiScene *scene = importer.ReadFile(ASSIMP_TEST_MODELS_DIR "/3D/box_a.3d", aiProcess_ValidateDataStructure);
|
||||||
|
ASSERT_NE(nullptr, scene);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue