From 0d20ee083b69d0cbde5a57a745386b987752af46 Mon Sep 17 00:00:00 2001 From: Vincent Richard Date: Wed, 5 Feb 2014 20:18:20 +0100 Subject: Better polling. Fixed possible connection issues on POSIX with slow network. Better error handling in POSIX sockets. --- tests/testUtils.cpp | 12 ++++++++++++ tests/testUtils.hpp | 3 +++ 2 files changed, 15 insertions(+) (limited to 'tests') diff --git a/tests/testUtils.cpp b/tests/testUtils.cpp index ee642bea..c4fce447 100644 --- a/tests/testUtils.cpp +++ b/tests/testUtils.cpp @@ -85,6 +85,18 @@ vmime::shared_ptr testSocket::getTimeoutHandler() } +bool testSocket::waitForRead(const int msecs) +{ + return true; +} + + +bool testSocket::waitForWrite(const int msecs) +{ + return true; +} + + void testSocket::receive(vmime::string& buffer) { buffer = m_inBuffer; diff --git a/tests/testUtils.hpp b/tests/testUtils.hpp index 9e72158a..20ebdf20 100644 --- a/tests/testUtils.hpp +++ b/tests/testUtils.hpp @@ -248,6 +248,9 @@ public: bool isConnected() const; + bool waitForWrite(const int msecs = 30000); + bool waitForRead(const int msecs = 30000); + void receive(vmime::string& buffer); void send(const vmime::string& buffer); void send(const char* str); -- cgit v1.2.3