diff --git a/examplar.cpp b/examplar.cpp index a0371b6..92d858a 100644 --- a/examplar.cpp +++ b/examplar.cpp @@ -4,6 +4,7 @@ int main( ) { + bool verbose = true; // A Plan is made up of Tasks, and a Suite is made up of Units. // A Plan declares what units are executed and a Suite declares the definitions of those units. Conf configuration = Conf("/home/phanes/Development/internal/Examplar/conf/config.json"); @@ -14,10 +15,7 @@ int main( ) // std::cout << definitions_file << std::endl << plan_file << std::endl; Suite available_definitions; - -// Suite * unit_definitions = new Suite(); - -// unit_definitions->load_file( definitions_file ); + available_definitions.load_units_file( definitions_file, verbose ); // Plan plan = Plan( plan_file ); diff --git a/src/loaders/Suite.cpp b/src/loaders/Suite.cpp index 4b1bd08..dc27924 100644 --- a/src/loaders/Suite.cpp +++ b/src/loaders/Suite.cpp @@ -50,6 +50,9 @@ void Suite::load_units_file( std::string filename, bool verbose ) tmp_U.load_root( this->json_root[ index ] ); // append to this->units this->units.push_back( tmp_U ); + if ( verbose ) { + std::cout << "Added unit " << tmp_U.get_name() << " to Suite." << std::endl; + } } } diff --git a/src/loaders/Task.cpp b/src/loaders/Task.cpp index 451f1b5..47d98a9 100644 --- a/src/loaders/Task.cpp +++ b/src/loaders/Task.cpp @@ -1,6 +1,5 @@ #include "Task.h" - Task::Task() {} Task::Task( Json::Value loader_root ) @@ -15,7 +14,6 @@ int Task::load_root(Json::Value loader_root) this->has_succeeded = false; } - std::string Task::get_name() { return this->name;