[Tests] Mock new argument in PlotController

This commit is contained in:
David Hudson
2016-09-03 13:51:37 +09:00
parent 40ad9c47a8
commit 92bfea1773

View File

@ -29,6 +29,7 @@ define(
describe("The plot controller", function () { describe("The plot controller", function () {
var mockScope, var mockScope,
mockElement,
mockFormatter, mockFormatter,
mockHandler, mockHandler,
mockThrottle, mockThrottle,
@ -65,6 +66,7 @@ define(
"$scope", "$scope",
["$watch", "$on", "$emit"] ["$watch", "$on", "$emit"]
); );
mockElement = angular.element('<div />');
mockFormatter = jasmine.createSpyObj( mockFormatter = jasmine.createSpyObj(
"formatter", "formatter",
["formatDomainValue", "formatRangeValue"] ["formatDomainValue", "formatRangeValue"]
@ -107,6 +109,7 @@ define(
controller = new PlotController( controller = new PlotController(
mockScope, mockScope,
mockElement,
mockFormatter, mockFormatter,
mockHandler, mockHandler,
mockThrottle mockThrottle