MCPcopy Create free account
hub / github.com/3rdparty/libprocess / FutureDispatch

Function FutureDispatch

include/process/gmock.hpp:540–553  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

538
539template <typename PID, typename Method>
540Future<Nothing> FutureDispatch(PID pid, Method method, bool drop = false)
541{
542 TestsFilter* filter = FilterTestEventListener::instance()->install();
543 Future<Nothing> future;
544 synchronized (filter->mutex) {
545 EXPECT_CALL(filter->mock, filter(pid, testing::A<const DispatchEvent&>()))
546 .With(DispatchMatcher(method))
547 .WillOnce(testing::DoAll(FutureSatisfy(&future),
548 testing::Return(drop)))
549 .RetiresOnSaturation(); // Don't impose any subsequent expectations.
550 }
551
552 return future;
553}
554
555
556template <typename Name, typename From, typename To>

Callers

nothing calls this directly

Calls 4

filterFunction · 0.85
FutureSatisfyFunction · 0.85
synchronizedFunction · 0.50
installMethod · 0.45

Tested by

no test coverage detected