Skip to content

Commit e7aa7a7

Browse files
Abhinav Kumaranutosh491
authored andcommitted
test coverage
1 parent 8e84776 commit e7aa7a7

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

unittests/CppInterOp/FunctionReflectionTest.cpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1514,7 +1514,7 @@ TEST(FunctionReflectionTest, UndoTest) {
15141514
testing::internal::CaptureStderr();
15151515
Cpp::Process("int y = x;");
15161516
cerrs = testing::internal::GetCapturedStderr();
1517-
EXPECT_TRUE(strstr(cerrs.c_str(), "error: use of undeclared identifier 'x'") != nullptr);
1517+
EXPECT_TRUE(strstr(cerrs.c_str(), "use of undeclared identifier 'x'") != nullptr);
15181518
testing::internal::CaptureStderr();
15191519
Cpp::Process("int x = 10;");
15201520
cerrs = testing::internal::GetCapturedStderr();
@@ -1532,4 +1532,11 @@ TEST(FunctionReflectionTest, UndoTest) {
15321532
Cpp::Process("int y = 20;");
15331533
cerrs = testing::internal::GetCapturedStderr();
15341534
EXPECT_STREQ(cerrs.c_str(), "");
1535+
1536+
int ret = Cpp::Undo(100);
1537+
#if defined(CPPINTEROP_USE_CLING)
1538+
EXPECT_EQ(ret, 0);
1539+
#else
1540+
EXPECT_EQ(ret, 1);
1541+
#endif
15351542
}

0 commit comments

Comments
 (0)