summaryrefslogtreecommitdiff
path: root/maximus/sci/src
diff options
context:
space:
mode:
authorburet2007-05-23 17:10:50 +0000
committerburet2007-05-23 17:10:50 +0000
commit3905547fcb619db3a1a76e815e371e1441979a2f (patch)
treefc57dfc9de877cbaa6787f82ab762163765abf9a /maximus/sci/src
parent8e6d96649434ca90513e0cd8102a27237259a380 (diff)
NetworkClockEvt implementation
git-svn-id: svn+ssh://pessac/svn/cesar/trunk@160 017c9cb6-072f-447c-8318-d5b54f68fe89
Diffstat (limited to 'maximus/sci/src')
-rw-r--r--maximus/sci/src/SciServerTest.cpp27
1 files changed, 7 insertions, 20 deletions
diff --git a/maximus/sci/src/SciServerTest.cpp b/maximus/sci/src/SciServerTest.cpp
index bed9fcfa58..28b78d8896 100644
--- a/maximus/sci/src/SciServerTest.cpp
+++ b/maximus/sci/src/SciServerTest.cpp
@@ -11,7 +11,7 @@
#include <iostream>
using namespace std;
-CPPUNIT_TEST_SUITE_REGISTRATION (SciServerTest);
+//CPPUNIT_TEST_SUITE_REGISTRATION (SciServerTest);
void SciServerTest::setUp (void)
@@ -54,12 +54,8 @@ void SciServerTest::receiveMsgTest (void)
cout << *((mpSciServer->getSpecializedSciMsgArray())+i) << endl;
}
- // Create data to send to SciServer
- //
- const char * tempData = "123456789011223344556677889900111222333444555666777888999000";
+
unsigned long dataLength = 60;
- unsigned char * pData = new unsigned char [dataLength];
- strcpy((char *)pData, tempData);
Sci_Msg_Header msgHeader = { 0, // uint32_t magic_id
dataLength, // uint16_t length
@@ -72,10 +68,10 @@ void SciServerTest::receiveMsgTest (void)
0xFFFF, // uint16_t reserved
0 }; //uint16_t flags
- receiveClockSciMsgTest (msgHeader, dataLength, pData);
- receivePhySciMsgTest (msgHeader, dataLength, pData);
- receiveSystemSciMsgTest (msgHeader, dataLength, pData);
- receiveFunctionSciMsgTest (msgHeader, dataLength, pData);
+ receiveClockSciMsgTest (msgHeader, dataLength, (unsigned char *)"123456789011223344556677889900111222333444555666777888999000");
+ receivePhySciMsgTest (msgHeader, dataLength, (unsigned char *)"123456789011223344556677889900111222333444555666777888999000");
+ receiveSystemSciMsgTest (msgHeader, dataLength, (unsigned char *)"123456789011223344556677889900111222333444555666777888999000");
+ receiveFunctionSciMsgTest (msgHeader, dataLength, (unsigned char *)"123456789011223344556677889900111222333444555666777888999000");
// Check results
//
@@ -90,18 +86,9 @@ void SciServerTest::receiveMsgTest (void)
cout << "SciMsg->mDataLength = " << (*((mpSciServer->getSpecializedSciMsgArray())+i))->getDataLength() << endl;
}
*/
- // Free allocated memory
- //
+
cout << "msgHeader = " << msgHeader.magic_id << " - " << msgHeader.flags << endl;
cout << "dataLength = " << dataLength << endl;
- cout << "pData = ";
- for (unsigned int i=0; i<dataLength; i++)
- {
- cout << *(pData+i);
- }
- cout << endl;
- delete [] pData;
- pData = NULL;
}