ADD: added tests
This commit is contained in:
@@ -34,6 +34,7 @@ SCENARIO("Testing the SimCore Sensor")
|
||||
track->setPosition(pos);
|
||||
track->Speed.setValue(speed);
|
||||
track->Course.setValue(course);
|
||||
auto SensorTrack = std::make_shared<SimCore::SensorTrack>(track);
|
||||
|
||||
|
||||
SimCore::SensorData Sensor1(SimCore::Identifier(),"ARPA","127.0.0.1", SimCore::SensorKinds::RADAR);
|
||||
@@ -45,7 +46,7 @@ SCENARIO("Testing the SimCore Sensor")
|
||||
|
||||
WHEN("constructing Track Object with data")
|
||||
{
|
||||
List.addTrack(track);
|
||||
List.addTrack(SensorTrack);
|
||||
THEN("check if Track attributes are correct")
|
||||
{
|
||||
|
||||
@@ -55,7 +56,7 @@ SCENARIO("Testing the SimCore Sensor")
|
||||
REQUIRE(List.getTrack(id)->Course.getValue() == course);
|
||||
// REQUIRE(List.getTrack(id)->getSensorCount() == 1);
|
||||
track->Course.setValue(270);
|
||||
List.addTrack(track);
|
||||
List.addTrack(SensorTrack);
|
||||
// REQUIRE(List.getTrack(id)->Course.getValue() == 270);
|
||||
// REQUIRE(List.getTrack(id)->getSensorCount() == 2);
|
||||
std::this_thread::sleep_for(std::chrono::milliseconds(3000));
|
||||
|
||||
Reference in New Issue
Block a user