From bd8bbc6e8f31f181f8780d74cc8acf431bd970e8 Mon Sep 17 00:00:00 2001 From: Victor Woeltjen Date: Tue, 27 Oct 2015 15:52:11 -0700 Subject: [PATCH] [Time Conductor] Update PlotController spec ...and add check to updateValues in PlotController, to reflect changes made to restore support for domain switching. --- platform/features/plot/src/PlotController.js | 8 ++++---- platform/features/plot/test/PlotControllerSpec.js | 6 ++++-- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/platform/features/plot/src/PlotController.js b/platform/features/plot/src/PlotController.js index 6d90325b85..d6acdb6a5c 100644 --- a/platform/features/plot/src/PlotController.js +++ b/platform/features/plot/src/PlotController.js @@ -149,11 +149,11 @@ define( if (handle) { setupModes(handle.getTelemetryObjects()); setupAxes(handle.getMetadata()); + getUpdater().update(); + self.modeOptions.getModeHandler().plotTelemetry(updater); + self.limitTracker.update(); + self.update(); } - getUpdater().update(); - self.modeOptions.getModeHandler().plotTelemetry(updater); - self.limitTracker.update(); - self.update(); } // Display new historical data as it becomes available diff --git a/platform/features/plot/test/PlotControllerSpec.js b/platform/features/plot/test/PlotControllerSpec.js index dcae177920..addbdf5032 100644 --- a/platform/features/plot/test/PlotControllerSpec.js +++ b/platform/features/plot/test/PlotControllerSpec.js @@ -169,8 +169,9 @@ define( mockDomainObject ]); - // Make an object available + // Make an object available; invoke handler's callback mockScope.$watch.mostRecentCall.args[1](mockDomainObject); + mockHandler.handle.mostRecentCall.args[1](); expect(controller.getModeOptions().length).toEqual(1); @@ -181,8 +182,9 @@ define( mockDomainObject ]); - // Make an object available + // Make an object available; invoke handler's callback mockScope.$watch.mostRecentCall.args[1](mockDomainObject); + mockHandler.handle.mostRecentCall.args[1](); expect(controller.getModeOptions().length).toEqual(2); });