You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by be...@apache.org on 2013/03/21 02:27:01 UTC
svn commit: r1459117 - /incubator/mesos/trunk/src/tests/allocator_tests.cpp
Author: benh
Date: Thu Mar 21 01:27:01 2013
New Revision: 1459117
URL: http://svn.apache.org/r1459117
Log:
Fixes the flaky AllocatorTest/ResourcesUnused test.
From: Thomas Marshall <tw...@gmail.com>
Review: https://reviews.apache.org/r/9996
Modified:
incubator/mesos/trunk/src/tests/allocator_tests.cpp
Modified: incubator/mesos/trunk/src/tests/allocator_tests.cpp
URL: http://svn.apache.org/viewvc/incubator/mesos/trunk/src/tests/allocator_tests.cpp?rev=1459117&r1=1459116&r2=1459117&view=diff
==============================================================================
--- incubator/mesos/trunk/src/tests/allocator_tests.cpp (original)
+++ incubator/mesos/trunk/src/tests/allocator_tests.cpp Thu Mar 21 01:27:01 2013
@@ -55,6 +55,7 @@ using std::string;
using std::vector;
using testing::_;
+using testing::AtMost;
using testing::ByRef;
using testing::DoAll;
using testing::DoDefault;
@@ -397,8 +398,14 @@ TYPED_TEST(AllocatorTest, ResourcesUnuse
PID<Master> master = process::spawn(m);
MockExecutor exec;
- trigger shutdownCall;
+ EXPECT_CALL(exec, registered(_, _, _, _))
+ .Times(AtMost(1));
+
+ EXPECT_CALL(exec, launchTask(_, _))
+ .Times(AtMost(1));
+
+ trigger shutdownCall;
EXPECT_CALL(exec, shutdown(_))
.WillOnce(Trigger(&shutdownCall));