Răsfoiți Sursa

Add unit test for formatting.

Malcolm Tyrrell 5 ani în urmă
părinte
comite
d7c65c36cd
1 a modificat fișierele cu 2 adăugiri și 2 ștergeri
  1. 2 2
      test/unit/utImporter.cpp

+ 2 - 2
test/unit/utImporter.cpp

@@ -313,7 +313,7 @@ namespace
         {
             if (pFile == "deadlyImportError.fail")
             {
-                throw DeadlyImportError("Deadly import error test");
+                throw DeadlyImportError("Deadly import error test. Details: ", 42, " More Details: ", "Failure");
             }
             else if (pFile == "stdException.fail")
             {
@@ -333,7 +333,7 @@ TEST_F(ImporterTest, deadlyImportError)
     pImp->SetIOHandler(new TestIOSystem);
     const aiScene* scene = pImp->ReadFile("deadlyImportError.fail", 0);
     EXPECT_EQ(scene, nullptr);
-    EXPECT_STREQ(pImp->GetErrorString(), "Deadly import error test");
+    EXPECT_STREQ(pImp->GetErrorString(), "Deadly import error test. Details: 42 More Details: Failure");
     EXPECT_NE(pImp->GetException(), std::exception_ptr());
 }