Browse Source

MeshTools: test a "shouldn't assert" case outside of an error redirect.

Because if it asserts, it would silently ignore that assert. It should
abort if it asserts.
pull/499/head
Vladimír Vondruš 3 years ago
parent
commit
91ed119690
  1. 3
      src/Magnum/MeshTools/Test/CompileGLTest.cpp

3
src/Magnum/MeshTools/Test/CompileGLTest.cpp

@ -1407,9 +1407,10 @@ void CompileGLTest::externalBuffersInvalid() {
nullptr, Trade::MeshIndexData{MeshIndexType::UnsignedInt, nullptr},
{}};
compile(data, GL::Buffer{NoCreate}, GL::Buffer{}); /* this is okay */
std::ostringstream out;
Error redirectError{&out};
compile(data, GL::Buffer{NoCreate}, GL::Buffer{}); /* this is okay */
compile(data, GL::Buffer{NoCreate}, GL::Buffer{NoCreate});
compile(indexedData, GL::Buffer{NoCreate}, GL::Buffer{});
CORRADE_COMPARE(out.str(),

Loading…
Cancel
Save