Browse Source

Test: use new TestSuite API to simplify things.

pull/491/head
Vladimír Vondruš 5 years ago
parent
commit
d2961f19f4
  1. 3
      src/Magnum/Math/Test/PackingBatchTest.cpp
  2. 9
      src/Magnum/MeshTools/Test/RemoveDuplicatesTest.cpp

3
src/Magnum/Math/Test/PackingBatchTest.cpp

@ -28,7 +28,6 @@
#include <Corrade/TestSuite/Tester.h>
#include <Corrade/TestSuite/Compare/Container.h>
#include <Corrade/Utility/DebugStl.h>
#include <Corrade/Utility/FormatStl.h>
#include "Magnum/Math/Color.h"
#include "Magnum/Math/Packing.h"
@ -651,7 +650,7 @@ template<class U, class T> void PackingBatchTest::assertionsCast() {
CORRADE_SKIP("CORRADE_NO_ASSERT defined, can't test assertions");
#endif
setTestCaseTemplateName(Corrade::Utility::formatString("{}, {}", TypeTraits<U>::name(), TypeTraits<T>::name()));
setTestCaseTemplateName({TypeTraits<U>::name(), TypeTraits<T>::name()});
Math::Vector2<T> data[2]{};
Math::Vector2<U> resultWrongCount[1]{};

9
src/Magnum/MeshTools/Test/RemoveDuplicatesTest.cpp

@ -30,7 +30,6 @@
#include <Corrade/TestSuite/Tester.h>
#include <Corrade/TestSuite/Compare/Container.h>
#include <Corrade/Utility/DebugStl.h>
#include <Corrade/Utility/FormatStl.h>
#include "Magnum/Math/Vector3.h"
#include "Magnum/MeshTools/RemoveDuplicates.h"
@ -494,9 +493,7 @@ void RemoveDuplicatesTest::removeDuplicatesFuzzyStl() {
#endif
template<class IndexType, class T> void RemoveDuplicatesTest::removeDuplicatesFuzzyIndexedInPlace() {
setTestCaseTemplateName(Utility::formatString("{}, {}",
Math::TypeTraits<IndexType>::name(),
Math::TypeTraits<T>::name()));
setTestCaseTemplateName({Math::TypeTraits<IndexType>::name(), Math::TypeTraits<T>::name()});
/* Same as above, but with an explicit index buffer */
IndexType indices[]{3, 2, 0, 1, 2, 3};
@ -557,9 +554,7 @@ void RemoveDuplicatesTest::removeDuplicatesFuzzyIndexedInPlaceEmptyIndicesVertic
}
template<class IndexType, class T> void RemoveDuplicatesTest::removeDuplicatesFuzzyIndexedInPlaceErased() {
setTestCaseTemplateName(Utility::formatString("{}, {}",
Math::TypeTraits<IndexType>::name(),
Math::TypeTraits<T>::name()));
setTestCaseTemplateName({Math::TypeTraits<IndexType>::name(), Math::TypeTraits<T>::name()});
/* Same as above, but with an explicit index buffer */
IndexType indices[]{3, 2, 0, 1, 2, 3};

Loading…
Cancel
Save