[ORC] Call ExecutionSession::endSession in unit tests.

2815ed57e3 added calls from ExecutorProcessControl::disconnect implementations
to shut down the TaskDispatcher. We still need to call endSession to trigger
disconnection though. This commit adds the necessary calls to the failing unit
tests.

https://llvm.org/PR52153
This commit is contained in:
Lang Hames 2021-10-12 14:27:39 -07:00
parent 2cadef6537
commit 19b4e3cfc6
1 changed files with 3 additions and 0 deletions

View File

@ -43,6 +43,7 @@ TEST(ExecutionSessionWrapperFunctionCalls, RunWrapperTemplate) {
ExecutorAddr::fromPtr(addWrapper), Result, 2, 3),
Succeeded());
EXPECT_EQ(Result, 5);
cantFail(ES.endSession());
}
TEST(ExecutionSessionWrapperFunctionCalls, RunVoidWrapperAsyncTemplate) {
@ -55,6 +56,7 @@ TEST(ExecutionSessionWrapperFunctionCalls, RunVoidWrapperAsyncTemplate) {
});
Error Err = RP.get_future().get();
EXPECT_THAT_ERROR(std::move(Err), Succeeded());
cantFail(ES.endSession());
}
TEST(ExecutionSessionWrapperFunctionCalls, RunNonVoidWrapperAsyncTemplate) {
@ -71,6 +73,7 @@ TEST(ExecutionSessionWrapperFunctionCalls, RunNonVoidWrapperAsyncTemplate) {
2, 3);
Expected<int32_t> Result = RP.get_future().get();
EXPECT_THAT_EXPECTED(Result, HasValue(5));
cantFail(ES.endSession());
}
TEST(ExecutionSessionWrapperFunctionCalls, RegisterAsyncHandlerAndRun) {