Fix UnitTest compilation

But running failed.
This commit is contained in:
Phenom 2017-05-04 15:01:25 +02:00
parent cac335e7f6
commit 1c2b43b7e0
19 changed files with 37 additions and 20 deletions

View File

@ -156,6 +156,19 @@ void RsNxsGrp::clear()
meta.TlvClear();
}
RsNxsGrp* RsNxsGrp::clone() const {
RsNxsGrp* grp = new RsNxsGrp(this->grp.tlvtype);
*grp = *this;
if(this->metaData)
{
grp->metaData = new RsGxsGrpMetaData();
*(grp->metaData) = *(this->metaData);
}
return grp;
}
void RsNxsSyncGrpReqItem::clear()
{
flag = 0;

View File

@ -1,6 +1,7 @@
#include <list>
#include "retroshare/rsids.h"
#include "rsitems/rsitem.h"
#include "serialiser/rsserial.h"
#include "testing/IsolatedServiceTester.h"

View File

@ -1,6 +1,8 @@
#include "SetFilter.h"
#include "rsitems/rsitem.h"
bool SetFilter::filter(const SetPacket &pkt)
{
switch(mFilterMode)

View File

@ -2,6 +2,7 @@
#include <list>
#include "retroshare/rsids.h"
#include "rsitems/rsitem.h"
#include "pqi/p3linkmgr.h"
#include "SetPacket.h"

View File

@ -1,6 +1,6 @@
#pragma once
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
#include "gxs/rsgxsdata.h"
#define RS_SERVICE_TYPE_PLUGIN_SIMPLE_FORUM 0x012

View File

@ -2,7 +2,7 @@
#define RSDATASERVICE_TEST_H
#include "util/rsthreads.h"
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
#include "gxs/rsgds.h"
void test_messageStoresAndRetrieve();

View File

@ -6,7 +6,7 @@
#include "gxs/rsnxs.h"
#include "gxs/rsgixs.h"
#include "serialiser/rsgxsitems.h"
#include "rsitems/rsgxsitems.h"
class RsDummyNetService: public RsNetworkExchangeService
{

View File

@ -28,7 +28,7 @@
*/
#include <gtest/gtest.h>
#include "serialiser/rsgxsiditems.h"
#include "rsitems/rsgxsiditems.h"
#include "support.h"

View File

@ -8,7 +8,7 @@
#include <gtest/gtest.h>
#include "support.h"
#include "serialiser/rsgxsupdateitems.h"
#include "rsitems/rsgxsupdateitems.h"
#define RS_SERVICE_TYPE_PLUGIN_SIMPLE_FORUM 0x0010
RsSerialType* init_item(RsGxsGrpUpdateItem& i)

View File

@ -26,7 +26,7 @@
#include <iostream>
#include "util/rsrandom.h"
#include "serialiser/rsmsgitems.h"
#include "rsitems/rsmsgitems.h"
#include "chat/rschatitems.h"
#include "support.h"
@ -141,7 +141,7 @@ RsSerialType* init_item(RsMsgItem& mi)
mi.sendTime = mi.recvTime;
mi.msgFlags = mi.recvTime;
return new RsMsgSerialiser(true);
return new RsMsgSerialiser(RsServiceSerializer::SERIALIZATION_FLAG_NONE);
}
RsSerialType* init_item(RsMsgTagType& mtt)
@ -150,7 +150,7 @@ RsSerialType* init_item(RsMsgTagType& mtt)
mtt.tagId = rand()%24242;
randString(SHORT_STR, mtt.text);
return new RsMsgSerialiser();
return new RsMsgSerialiser(RsServiceSerializer::SERIALIZATION_FLAG_NONE);
}
@ -163,7 +163,7 @@ RsSerialType* init_item(RsMsgTags& mt)
mt.tagIds.push_back(rand()%21341);
}
return new RsMsgSerialiser();
return new RsMsgSerialiser(RsServiceSerializer::SERIALIZATION_FLAG_NONE);
}
RsSerialType* init_item(RsMsgSrcId& ms)
@ -171,7 +171,7 @@ RsSerialType* init_item(RsMsgSrcId& ms)
ms.msgId = rand()%434;
ms.srcId = RsPeerId::random();
return new RsMsgSerialiser();
return new RsMsgSerialiser(RsServiceSerializer::SERIALIZATION_FLAG_NONE);
}
RsSerialType* init_item(RsMsgParentId& ms)
@ -179,7 +179,7 @@ RsSerialType* init_item(RsMsgParentId& ms)
ms.msgId = rand()%354;
ms.msgParentId = rand()%476;
return new RsMsgSerialiser();
return new RsMsgSerialiser(RsServiceSerializer::SERIALIZATION_FLAG_NONE);
}
bool operator ==(const struct VisibleChatLobbyInfo& l, const struct VisibleChatLobbyInfo& r)

View File

@ -1,7 +1,7 @@
#include "support.h"
#include "libretroshare/gxs/common/data_support.h"
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
#define NUM_BIN_OBJECTS 5

View File

@ -25,7 +25,7 @@
#include "support.h"
#include "serialiser/rsstatusitems.h"
#include "rsitems/rsstatusitems.h"
RsSerialType* init_item(RsStatusItem& rsi)
{

View File

@ -5,7 +5,7 @@
// from libretroshare
#include "services/p3statusservice.h"
#include "serialiser/rsstatusitems.h"
#include "rsitems/rsstatusitems.h"
#include "gxs/rsgixs.h"
#include "gxs/rsdataservice.h"
#include "gxs/rsgxsnetservice.h"

View File

@ -5,7 +5,7 @@
#include "gxstestservice.h"
// libretroshare
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
GxsPairServiceTester::GxsPairServiceTester(const RsPeerId &peerId1, const RsPeerId &peerId2, int testMode, bool useIdentityService)
:SetServiceTester()

View File

@ -4,7 +4,7 @@
// from librssimulator
// from libretroshare
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
// local
#include "GxsPairServiceTester.h"

View File

@ -8,7 +8,7 @@
//#include "gxs/rsgixs.h"
//#include "gxs/rsdataservice.h"
//#include "gxs/rsgxsnetservice.h"
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
// local
#include "GxsIsolatedServiceTester.h"

View File

@ -4,7 +4,7 @@
// from librssimulator
// from libretroshare
#include "serialiser/rsnxsitems.h"
#include "rsitems/rsnxsitems.h"
// local
#include "GxsPairServiceTester.h"

View File

@ -30,7 +30,7 @@
#include "rsitems/rsserviceids.h"
#include "serialiser/rsserial.h"
#include "serialiser/rsgxsitems.h"
#include "rsitems/rsgxsitems.h"
#include "gxstestservice.h"
const uint8_t RS_PKT_SUBTYPE_TEST_GROUP_ITEM = 0x02;

View File

@ -7,7 +7,7 @@
// from libretroshare
#include "services/p3statusservice.h"
#include "serialiser/rsstatusitems.h"
#include "rsitems/rsstatusitems.h"
#define N_PEERS 10