mirror of
https://github.com/apache/zeppelin
synced 2026-05-24 09:38:26 +00:00
test: fix test for jasmine-core 2.x
ref - http://stackoverflow.com/questions/27680933/jasmine-have-createspy-return-mock-object
This commit is contained in:
parent
ded1f2c0dc
commit
ac40b5690d
2 changed files with 4 additions and 3 deletions
|
|
@ -38,6 +38,7 @@
|
|||
"grunt-svgmin": "^0.4.0",
|
||||
"grunt-usemin": "^2.1.1",
|
||||
"grunt-wiredep": "~2.0.0",
|
||||
"jasmine-core": "^2.5.2",
|
||||
"karma": "~1.3.0",
|
||||
"karma-coverage": "^1.1.1",
|
||||
"karma-jasmine": "~1.0.2",
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ describe('Controller: ParagraphCtrl', function() {
|
|||
|
||||
it('should call loadTableData() and getGraphMode() should return "table" when the result type is "TABLE"',
|
||||
function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').andCallFake(function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').and.callFake(function() {
|
||||
return 'TABLE';
|
||||
});
|
||||
spyOn(scope, 'setGraphMode');
|
||||
|
|
@ -71,7 +71,7 @@ describe('Controller: ParagraphCtrl', function() {
|
|||
});
|
||||
|
||||
it('should call renderHtml() when the result type is "HTML"', function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').andCallFake(function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').and.callFake(function() {
|
||||
return 'HTML';
|
||||
});
|
||||
spyOn(scope, 'renderHtml');
|
||||
|
|
@ -80,7 +80,7 @@ describe('Controller: ParagraphCtrl', function() {
|
|||
});
|
||||
|
||||
it('should call renderAngular() when the result type is "ANGULAR"', function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').andCallFake(function() {
|
||||
scope.getResultType = jasmine.createSpy('getResultType spy').and.callFake(function() {
|
||||
return 'ANGULAR';
|
||||
});
|
||||
spyOn(scope, 'renderAngular');
|
||||
|
|
|
|||
Loading…
Reference in a new issue