X-Git-Url: https://git.teslayout.com/public/public/public/?a=blobdiff_plain;f=example%2Fdiameter%2Flauncher%2Ftesting%2FTestCase.hpp;h=715856a96039c68712c9260227ede05569a51e92;hb=c6b62fd814b6e5b4e3ba65b6f092f6aa4e1d298d;hp=a3b653de24efbe02a432633b6d89293e509f3c44;hpb=687b0fa0b7c8440f71837334b0b29c28dfae2dca;p=anna.git diff --git a/example/diameter/launcher/testing/TestCase.hpp b/example/diameter/launcher/testing/TestCase.hpp index a3b653d..715856a 100644 --- a/example/diameter/launcher/testing/TestCase.hpp +++ b/example/diameter/launcher/testing/TestCase.hpp @@ -12,6 +12,7 @@ // Standard #include #include +#include // Project #include @@ -56,7 +57,7 @@ public: anna::xml::Node* asXML(anna::xml::Node* parent) const throw(); }; - TestCase(unsigned int id) : a_id(id), a_state(State::Initialized), a_startTime(0), a_interactiveAmount(-1) { /*a_stepsIt = a_steps.end()*/;} + TestCase(unsigned int id); ~TestCase(); struct State { enum _v { Initialized, InProgress, Failed, Success }; }; @@ -108,6 +109,8 @@ public: //helpers int steps() const throw() { return a_steps.size(); } + void addStep(TestStep *step) throw() { a_steps.push_back(step); } + TestStepWait *searchNextWaitConditionFulfilled(const anna::DataBlock &message, bool waitFromEntity) throw(); // When a message arrives, we identify the test case by mean the Session-Id. Then, from the current step iterator (included), // we search for a fulfilling condition for that message. The first found, is 'completed' and then breaks the search.