mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-11-13 13:43:53 +01:00
tsquash
This commit is contained in:
1 parent
5292075a0a
commit
dfbf7ab39a
6 files changed
+69
-20
No files matched your search
@@ -2,6 +2,7 @@
|
||||
#include "catch.hpp"
|
||||
|
||||
#include <type_traits>
|
||||
#include <string>
|
||||
|
||||
using sls::Result;
|
||||
|
||||
@@ -73,3 +74,13 @@ TEST_CASE("equal", "[n2]"){
|
||||
res.push_back(1.3);
|
||||
REQUIRE(res.equal() == false);
|
||||
}
|
||||
|
||||
TEST_CASE("throws for tsquash", "[n2]"){
|
||||
Result<int> res{1,2,3};
|
||||
REQUIRE_THROWS(res.tsquash("something is wrong"));
|
||||
}
|
||||
|
||||
TEST_CASE("", "[n2]"){
|
||||
Result<std::string> res{"hej", "hej", "hej"};
|
||||
REQUIRE(res.squash() == "hej");
|
||||
}
|
||||
Reference in new issue
Block a user