27 #ifndef SPORE_TEST_MODULE_H 28 #define SPORE_TEST_MODULE_H 30 #include "dictutils.h" 32 #include "tracing_node.h" 33 #include "spore_test_base.h" 34 #include "spore_names.h" 55 using nest::Node::handle;
56 using nest::Node::handles_test_event;
58 void handle(nest::SpikeEvent&);
60 nest::port
send_test_event(nest::Node&, nest::rport, nest::synindex,
bool);
67 void init_state_(
const nest::Node& proto);
71 void update(nest::Time
const&,
const long,
const long);
73 std::string test_name_;
76 std::map<std::string, SporeTestBase*> tests_;
88 return target.handles_test_event(e, receptor_type);
106 def<std::string>(d, names::test_name, test_name_);
107 def<double>(d, names::test_time, test_time_);
108 if (not test_name_.empty())
122 std::string test_name;
123 if (updateValue<std::string>(d, names::test_name, test_name))
125 if (tests_.find(test_name) == tests_.end())
126 throw nest::BadParameter(
"test '" + test_name +
"' does not exist!");
128 test_name_ = test_name;
132 updateValue<double>(d, names::test_time, test_time_);
134 if (not test_name_.empty())
136 tests_[test_name_]->set_status(d);
void handle(nest::SpikeEvent &)
Definition: spore_test_node.cpp:96
nest::port send_test_event(nest::Node &, nest::rport, nest::synindex, bool)
Definition: spore_test_node.h:83
~SporeTestNode()
Definition: spore_test_node.cpp:51
Base class to all nodes that record traces.
Definition: tracing_node.h:52
Base class to all tests.
Definition: spore_test_base.h:43
Node to test the SPORE module.
Definition: spore_test_node.h:42
void register_test(SporeTestBase *test)
Definition: spore_test_node.cpp:62
Global namespace holding all classes of the SPORE NEST module.
Definition: circular_buffer.h:31
void set_status(const DictionaryDatum &)
Definition: spore_test_node.h:120
SporeTestNode()
Definition: spore_test_node.cpp:40
void get_status(DictionaryDatum &) const
Definition: spore_test_node.h:104
nest::port handles_test_event(nest::SpikeEvent &, nest::rport)
Definition: spore_test_node.h:95