From 29de01b458401615d56a8c9ebbda5e0c7805e9eb Mon Sep 17 00:00:00 2001 From: subtly Date: Sun, 25 Jan 2015 21:43:53 -0800 Subject: add test-require to p2p/host --- peer.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'peer.cpp') diff --git a/peer.cpp b/peer.cpp index 7c128276..a4b07e0b 100644 --- a/peer.cpp +++ b/peer.cpp @@ -44,7 +44,10 @@ BOOST_AUTO_TEST_CASE(host) host1.addNode(node2, "127.0.0.1", host2prefs.listenPort, host2prefs.listenPort); - this_thread::sleep_for(chrono::seconds(3)); + this_thread::sleep_for(chrono::seconds(1)); + + BOOST_REQUIRE_EQUAL(host1.peerCount(), 1); + BOOST_REQUIRE_EQUAL(host2.peerCount(), host1.peerCount()); } BOOST_AUTO_TEST_SUITE_END() -- cgit