[tests] Another batch of timeout increases.
authorDaniel Dunbar <daniel@zuster.org>
Mon, 11 Feb 2013 21:04:34 +0000 (21:04 +0000)
committerDaniel Dunbar <daniel@zuster.org>
Mon, 11 Feb 2013 21:04:34 +0000 (21:04 +0000)
llvm-svn: 174902

libcxx/test/thread/futures/futures.unique_future/wait_for.pass.cpp
libcxx/test/thread/thread.condition/thread.condition.condvar/wait_for.pass.cpp
libcxx/test/thread/thread.condition/thread.condition.condvar/wait_for_pred.pass.cpp
libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_for.pass.cpp
libcxx/test/thread/thread.condition/thread.condition.condvarany/wait_until_pred.pass.cpp
libcxx/test/thread/thread.mutex/thread.mutex.requirements/thread.timedmutex.requirements/thread.timedmutex.recursive/lock.pass.cpp
libcxx/test/thread/thread.threads/thread.thread.this/sleep_for.pass.cpp
libcxx/test/thread/thread.threads/thread.thread.this/sleep_until.pass.cpp

index 796b75a..2a81a2c 100644 (file)
@@ -58,7 +58,7 @@ int main()
         f.wait();
         Clock::time_point t1 = Clock::now();
         assert(f.valid());
-        assert(t1-t0 < ms(5));
+        assert(t1-t0 < ms(50));
     }
     {
         typedef int& T;
@@ -74,7 +74,7 @@ int main()
         f.wait();
         Clock::time_point t1 = Clock::now();
         assert(f.valid());
-        assert(t1-t0 < ms(5));
+        assert(t1-t0 < ms(50));
     }
     {
         typedef void T;
@@ -90,6 +90,6 @@ int main()
         f.wait();
         Clock::time_point t1 = Clock::now();
         assert(f.valid());
-        assert(t1-t0 < ms(5));
+        assert(t1-t0 < ms(50));
     }
 }
index 6c94e72..038c946 100644 (file)
@@ -50,7 +50,7 @@ void f()
     }
     else
     {
-        assert(t1 - t0 - milliseconds(250) < milliseconds(10));
+        assert(t1 - t0 - milliseconds(250) < milliseconds(50));
         assert(test2 == 0);
     }
     ++runs;
index 930841d..ef7a9b6 100644 (file)
@@ -58,7 +58,7 @@ void f()
     }
     else
     {
-        assert(t1 - t0 - milliseconds(250) < milliseconds(10));
+        assert(t1 - t0 - milliseconds(250) < milliseconds(50));
         assert(test2 == 0);
     }
     ++runs;
index d50ad40..89759ac 100644 (file)
@@ -53,7 +53,7 @@ void f()
     }
     else
     {
-        assert(t1 - t0 - milliseconds(250) < milliseconds(5));
+        assert(t1 - t0 - milliseconds(250) < milliseconds(50));
         assert(test2 == 0);
     }
     ++runs;
index 6a7a132..1490e11 100644 (file)
@@ -79,7 +79,7 @@ void f()
     }
     else
     {
-        assert(t1 - t0 - Clock::duration(250) < Clock::duration(5));
+        assert(t1 - t0 - Clock::duration(250) < Clock::duration(50));
         assert(test2 == 0);
         assert(!r);
     }
index 2d5b4ac..d66db3f 100644 (file)
@@ -26,7 +26,7 @@ int main()
     std::this_thread::sleep_for(ms);
     time_point t1 = Clock::now();
     std::chrono::nanoseconds ns = (t1 - t0) - ms;
-    std::chrono::nanoseconds err = ms / 100;
-    // The time slept is within 1% of 500ms
+    std::chrono::nanoseconds err = 5 * ms / 100;
+    // The time slept is within 5% of 500ms
     assert(std::abs(ns.count()) < err.count());
 }
index c0bf087..2f3bb9a 100644 (file)
@@ -26,7 +26,7 @@ int main()
     std::this_thread::sleep_until(t0 + ms);
     time_point t1 = Clock::now();
     std::chrono::nanoseconds ns = (t1 - t0) - ms;
-    std::chrono::nanoseconds err = ms / 100;
-    // The time slept is within 1% of 500ms
+    std::chrono::nanoseconds err = 5 * ms / 100;
+    // The time slept is within 5% of 500ms
     assert(std::abs(ns.count()) < err.count());
 }