Selaa lähdekoodia

Fixed event admin unit test.

The old ctkDictionary class lead to wrong behavior when matching
ctkEventHandler services containg a filter string with the events
send through the event admin (property keys where matched case
insensitively). Since this has been fixed, the number of consumed
events is different now (1).
Sascha Zelzer 12 vuotta sitten
vanhempi
commit
6e36fd563b

+ 1 - 1
Libs/PluginFramework/Testing/org.commontk.eventadmintest/ctkEAScenario4TestSuite.cpp

@@ -234,7 +234,7 @@ void ctkEAScenario4TestSuite::initTestCase()
   eventConsumers.push_back(new ctkEAScenario4EventConsumer(pluginContext, scenario4_topics1,
                                                            1, 1, scenario4_filter1));
   eventConsumers.push_back(new ctkEAScenario4EventConsumer(pluginContext, scenario4_topics1,
-                                                           2, 2, scenario4_filter2));
+                                                           1, 1, scenario4_filter2));
   eventConsumers.push_back(new ctkEAScenario4EventConsumer(pluginContext, scenario4_topics1,
                                                            0, 0, scenario4_filter3));
   eventConsumers.push_back(new ctkEAScenario4EventConsumer(pluginContext, scenario4_topics1,

+ 9 - 2
Libs/PluginFramework/Testing/org.commontk.eventadmintest/ctkEventAdminTestActivator.cpp

@@ -35,8 +35,13 @@
 
 //----------------------------------------------------------------------------
 ctkEventAdminTestActivator::ctkEventAdminTestActivator()
-  : topicWildcardTestSuite(0), topicWildcardTestSuiteSS(0),
-    scenario1TestSuite(0), scenario1TestSuiteSS(0), scenario2TestSuite(0)
+  : topicWildcardTestSuite(0)
+  , topicWildcardTestSuiteSS(0)
+  , scenario1TestSuite(0)
+  , scenario1TestSuiteSS(0)
+  , scenario2TestSuite(0)
+  , scenario3TestSuite(0)
+  , scenario4TestSuite(0)
 {
 
 }
@@ -49,6 +54,8 @@ ctkEventAdminTestActivator::~ctkEventAdminTestActivator()
   delete scenario1TestSuite;
   delete scenario1TestSuiteSS;
   delete scenario2TestSuite;
+  delete scenario3TestSuite;
+  delete scenario4TestSuite;
 }
 
 //----------------------------------------------------------------------------