Skip to content

Commit

Permalink
Update test_parreduce.cpp: put in times
Browse files Browse the repository at this point in the history
  • Loading branch information
vlkale authored Apr 6, 2024
1 parent 336e304 commit 69c694a
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions tests/sampler/test_parreduce.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@

using ::testing::HasSubstr;
using ::testing::Not;
using ::testing::Contains;
using ::testing::Times;

struct Tester {
template <typename execution_space>
explicit Tester(const execution_space& space) {
Expand Down Expand Up @@ -69,6 +72,20 @@ TEST(SamplerTest, ktoEnvVarDefault) {
EXPECT_THAT(output.str(), HasSubstr(matcher));
}

EXPECT_THAT(output.str(),
::testing::Contains.Times(static_cast<int>(2),
"calling child-begin function..."));
EXPECT_THAT(output.str(),
::testing::Contains.Times(static_cast<int>(2),
"finished with child-begin function."));

EXPECT_THAT(output.str(),
::testing::Contains.Times(static_cast<int>(2),
"calling child-end function..."));
EXPECT_THAT(output.str(),
::testing::Contains.Times(static_cast<int>(2),
"finished with child-end function."));

EXPECT_THAT(output.str(), Not(HasSubstr("KokkosP: FATAL: No child library of "
"sampler utility library to call")));

Expand Down

0 comments on commit 69c694a

Please sign in to comment.