allow command to accept "--" separator
[folly.git] / folly / experimental / test / FunctionSchedulerTest.cpp
index b869f2a856eea59515768fa6086819f4061b5d2b..4df2e7aebaaa4fed8655068879cf6bd6915a59ff 100644 (file)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2017 Facebook, Inc.
+ * Copyright 2015-present Facebook, Inc.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -629,7 +629,7 @@ TEST(FunctionScheduler, CancelAndWaitOnRunningFunc) {
     baton.post();
   });
 
-  ASSERT_TRUE(baton.timed_wait(testInterval(15)));
+  ASSERT_TRUE(baton.try_wait_for(testInterval(15)));
   th.join();
 }
 
@@ -644,7 +644,7 @@ TEST(FunctionScheduler, CancelAllAndWaitWithRunningFunc) {
     baton.post();
   });
 
-  ASSERT_TRUE(baton.timed_wait(testInterval(15)));
+  ASSERT_TRUE(baton.try_wait_for(testInterval(15)));
   th.join();
 }
 
@@ -675,7 +675,7 @@ TEST(FunctionScheduler, CancelAllAndWaitWithOneRunningAndOneWaiting) {
     baton.post();
   });
 
-  ASSERT_TRUE(baton.timed_wait(testInterval(15)));
+  ASSERT_TRUE(baton.try_wait_for(testInterval(15)));
   th.join();
 }