From 9937b14ff89e845573f6893aafbb84fd5e4f5ab4 Mon Sep 17 00:00:00 2001 From: Stephane Del Pino <stephane.delpino44@gmail.com> Date: Mon, 11 Jun 2018 11:14:04 +0200 Subject: [PATCH] Replaced REQUIRE_NOTHROW -> REQUIRE for tests. REQUIRE_NOTHROW just checks that no exceptions are thrown, does not check the validity of the result --- tests/test_TinyVector.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_TinyVector.cpp b/tests/test_TinyVector.cpp index e61942a7f..38588a6b4 100644 --- a/tests/test_TinyVector.cpp +++ b/tests/test_TinyVector.cpp @@ -5,18 +5,18 @@ TEST_CASE("TinyVector", "[algebra]") { TinyVector<3,int> v(1,2,3); - REQUIRE_NOTHROW(((v[0] == 1) and (v[1] == 2) and (v[2] == 3))); + REQUIRE(((v[0] == 1) and (v[1] == 2) and (v[2] == 3))); REQUIRE(v.dimension() == 3); const TinyVector<3,int> z = zero; - REQUIRE_NOTHROW(((z[0] == 0) and (z[1] == 0) and (z[2] == 0))); + REQUIRE(((z[0] == 0) and (z[1] == 0) and (z[2] == 0))); v = TinyVector<3,int>(3,2,4); TinyVector<3,int> w(1,2,6); REQUIRE((v,w)==31); w = 2*v; - REQUIRE_NOTHROW(((w[0] == 2*v[0]) and (w[1]==2*v[1]) and (w[2]==2*v[2]))); + REQUIRE(((w[0] == 2*v[0]) and (w[1]==2*v[1]) and (w[2]==2*v[2]))); TinyVector<3,int> x = v; REQUIRE(x==v); @@ -43,7 +43,7 @@ TEST_CASE("TinyVector", "[algebra]") { REQUIRE(x==v); TinyVector<3,int> z1; z1 = zero; - REQUIRE_NOTHROW(((z1[0] == 0) and (z1[1] == 0) and (z1[2] == 0))); + REQUIRE(((z1[0] == 0) and (z1[1] == 0) and (z1[2] == 0))); REQUIRE(Catch::Detail::stringify(x) == "(3,2,4)"); -- GitLab