From f6638c0b0734c6202716ec03fb1e93382dcccb68 Mon Sep 17 00:00:00 2001 From: yuyang18 Date: Sat, 19 May 2018 21:23:51 +0800 Subject: [PATCH] Disable buggy tests --- paddle/fluid/operators/detail/grpc_server_test.cc | 5 ++++- python/paddle/fluid/tests/unittests/test_dist_train.py | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/paddle/fluid/operators/detail/grpc_server_test.cc b/paddle/fluid/operators/detail/grpc_server_test.cc index b8db0ad98..20b9dc631 100644 --- a/paddle/fluid/operators/detail/grpc_server_test.cc +++ b/paddle/fluid/operators/detail/grpc_server_test.cc @@ -108,7 +108,10 @@ void StartServer(const std::string& endpoint) { rpc_service_->RunSyncUpdate(); } -TEST(PREFETCH, CPU) { +// NOTE(yuyang18) : This test is buggy. +// 1. We should not use port 8889 before check. +// 2. We should not use sleep(2) to sync threads. +TEST(PREFETCH, DISABLE_CPU) { // start up a server instance backend std::thread server_thread(StartServer, "127.0.0.1:8889"); sleep(2); diff --git a/python/paddle/fluid/tests/unittests/test_dist_train.py b/python/paddle/fluid/tests/unittests/test_dist_train.py index 77e9a8f7e..58278ff82 100644 --- a/python/paddle/fluid/tests/unittests/test_dist_train.py +++ b/python/paddle/fluid/tests/unittests/test_dist_train.py @@ -25,6 +25,9 @@ import time class TestSendOp(unittest.TestCase): + @unittest.skip( + "This test is buggy. We cannot use time.sleep to sync processes, the connection may fail in unittest." + ) def test_send(self): # Run init_serv in a thread place = fluid.CPUPlace() -- GitLab