Ray Milkey

Unit tests for Objective Tracker

- Fixed a bug in ObjectiveTracker turned up by tests, it
  could not handle an emptry list (it was checking for null only)
- Implemented tests for topology, resource and leadership
  events

Change-Id: I1318a0e8655f5b44b30d2ecb527f665f13d54243
...@@ -178,7 +178,7 @@ public class ObjectiveTracker implements ObjectiveTrackerService { ...@@ -178,7 +178,7 @@ public class ObjectiveTracker implements ObjectiveTrackerService {
178 return; 178 return;
179 } 179 }
180 180
181 - if (event.reasons() == null) { 181 + if (event.reasons() == null || event.reasons().isEmpty()) {
182 delegate.triggerCompile(new HashSet<IntentId>(), true); 182 delegate.triggerCompile(new HashSet<IntentId>(), true);
183 183
184 } else { 184 } else {
......