aboutsummaryrefslogtreecommitdiffstats
path: root/tests/testUtils.hpp
diff options
context:
space:
mode:
authorVincent Richard <[email protected]>2013-12-10 07:52:51 +0000
committerVincent Richard <[email protected]>2013-12-10 07:52:51 +0000
commit7e265b05f440ed81b80f2de496c9d13221a69fe0 (patch)
treed4dad210715ea9d60b2136bd416647d4bc02166a /tests/testUtils.hpp
parentEnforce strict aliasing rule and avoid alignment issues. (diff)
downloadvmime-7e265b05f440ed81b80f2de496c9d13221a69fe0.tar.gz
vmime-7e265b05f440ed81b80f2de496c9d13221a69fe0.zip
Simplified types for better readability. Use appropriate types (size_t, byte_t...). Minor warning fixes.
Diffstat (limited to 'tests/testUtils.hpp')
-rw-r--r--tests/testUtils.hpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/tests/testUtils.hpp b/tests/testUtils.hpp
index fdcca575..f0ecf454 100644
--- a/tests/testUtils.hpp
+++ b/tests/testUtils.hpp
@@ -250,12 +250,13 @@ public:
void receive(vmime::string& buffer);
void send(const vmime::string& buffer);
+ void send(const char* str);
- size_type receiveRaw(char* buffer, const size_type count);
- void sendRaw(const char* buffer, const size_type count);
- size_type sendRawNonBlocking(const char* buffer, const size_type count);
+ size_t receiveRaw(vmime::byte_t* buffer, const size_t count);
+ void sendRaw(const vmime::byte_t* buffer, const size_t count);
+ size_t sendRawNonBlocking(const vmime::byte_t* buffer, const size_t count);
- size_type getBlockSize() const;
+ size_t getBlockSize() const;
unsigned int getStatus() const;
@@ -287,7 +288,7 @@ public:
* @param count number of bytes to receive
* @return number of bytes received
*/
- testSocket::size_type localReceiveRaw(char* buffer, const size_type count);
+ vmime::size_t localReceiveRaw(vmime::byte_t* buffer, const size_t count);
protected:
@@ -349,7 +350,7 @@ class testTimeoutHandler : public vmime::net::timeoutHandler
{
public:
- testTimeoutHandler(const unsigned int delay = 3);
+ testTimeoutHandler(const unsigned long delay = 3);
bool isTimeOut();
void resetTimeOut();
@@ -357,8 +358,8 @@ public:
private:
- unsigned int m_delay;
- unsigned int m_start;
+ unsigned long m_delay;
+ unsigned long m_start;
};