MCPcopy Create free account
hub / github.com/apache/arrow / TEST_F

Function TEST_F

cpp/src/arrow/util/cancel_test.cc:47–65  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

45class CancelTest : public ::testing::Test {};
46
47TEST_F(CancelTest, StopBasics) {
48 {
49 StopSource source;
50 StopToken token = source.token();
51 ASSERT_FALSE(token.IsStopRequested());
52 ASSERT_OK(token.Poll());
53
54 source.RequestStop();
55 ASSERT_TRUE(token.IsStopRequested());
56 ASSERT_RAISES(Cancelled, token.Poll());
57 }
58 {
59 StopSource source;
60 StopToken token = source.token();
61 source.RequestStop(Status::IOError("Operation cancelled"));
62 ASSERT_TRUE(token.IsStopRequested());
63 ASSERT_RAISES(IOError, token.Poll());
64 }
65}
66
67TEST_F(CancelTest, StopTokenCopy) {
68 StopSource source;

Callers

nothing calls this directly

Calls 15

IOErrorFunction · 0.85
UnstoppableFunction · 0.85
SetITimerFunction · 0.85
BusyWaitFunction · 0.85
SignalFromStatusFunction · 0.85
SleepForFunction · 0.85
tokenMethod · 0.80
IsStopRequestedMethod · 0.80
PollMethod · 0.80
RequestStopMethod · 0.80
emplace_backMethod · 0.80

Tested by

no test coverage detected