mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-29 04:17:55 +01:00
Add android build on travis (#1981)
* Add build for android in travis CI. * Fix review findings. Change from __ANDORID__ to POCO_ANDROID * Add android test * Fix compile issue after rebase * Ignore test big ping when its failing
This commit is contained in:
committed by
Aleksandar Fabijanic
parent
d162110e67
commit
9feabc7723
@@ -47,15 +47,23 @@ MulticastSocketTest::~MulticastSocketTest()
|
||||
|
||||
void MulticastSocketTest::testMulticast()
|
||||
{
|
||||
MulticastEchoServer echoServer;
|
||||
MulticastSocket ms(SocketAddress::IPv4);
|
||||
int n = ms.sendTo("hello", 5, echoServer.group());
|
||||
assert (n == 5);
|
||||
char buffer[256];
|
||||
n = ms.receiveBytes(buffer, sizeof(buffer));
|
||||
assert (n == 5);
|
||||
assert (std::string(buffer, n) == "hello");
|
||||
ms.close();
|
||||
try {
|
||||
MulticastEchoServer echoServer;
|
||||
MulticastSocket ms(SocketAddress::IPv4);
|
||||
int n = ms.sendTo("hello", 5, echoServer.group());
|
||||
assert (n == 5);
|
||||
char buffer[256];
|
||||
n = ms.receiveBytes(buffer, sizeof(buffer));
|
||||
assert (n == 5);
|
||||
assert (std::string(buffer, n) == "hello");
|
||||
ms.close();
|
||||
}
|
||||
catch(Poco::NotImplementedException e)
|
||||
{
|
||||
#ifndef POCO_ANDROID
|
||||
throw e;
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user