Skip to content

Commit

Permalink
Update test to actually start the network
Browse files Browse the repository at this point in the history
  • Loading branch information
maniacbug committed Dec 16, 2011
1 parent fc43ebc commit 6754887
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions tests/unit/TemplateTest.test → tests/unit/RF24NetworkTest.test
Original file line number Diff line number Diff line change
Expand Up @@ -16,27 +16,35 @@
#include <cxxtest/TestSuite.h>
// Project headers
// This component's header
#include <Template.h>
#include <RF24Network.h>
#include <RF24.h>

#include "WProgram.h"

HardwareSPI SPI(2);

// Radio on Maple Native w/ Getting Started board
RF24 radio(7,6);
RF24Network network(radio);

using namespace std;

class TemplateTestSuite: public CxxTest::TestSuite
{
Template* pTemplate ;
public:
void setUp()
{
pTemplate = new Template();
SPI.begin();
radio.begin();
network.begin(100,0);
}

void tearDown()
{
delete pTemplate;
}

void testEmpty( void )
{
TS_ASSERT(pTemplate);
}
};
// vim:cin:ai:sts=2 sw=2 ft=cpp

0 comments on commit 6754887

Please sign in to comment.