Skip to content
This repository was archived by the owner on Sep 8, 2020. It is now read-only.

Commit 00f5263

Browse files
committed
chore: upgrade karma PhantomJS and Jasmine
1 parent 61c50b4 commit 00f5263

File tree

4 files changed

+23
-24
lines changed

4 files changed

+23
-24
lines changed

package.json

+11-10
Original file line numberDiff line numberDiff line change
@@ -15,21 +15,22 @@
1515
"grunt-contrib-uglify": "0.2.x",
1616
"grunt-contrib-watch": "0.5.x",
1717
"grunt-conventional-changelog": "~1.0.0",
18-
"grunt-karma": "0.6.x",
18+
"grunt-karma": "^0.12.1",
1919
"grunt-ngmin": "0.0.x",
2020
"grunt-surround": "0.1.x",
21-
"karma": "0.10.x",
21+
"jasmine-core": "^2.4.1",
22+
"karma": "^0.13.22",
2223
"karma-chrome-launcher": "0.1.x",
23-
"karma-coffee-preprocessor": "0.1.x",
24-
"karma-coverage": "~0.2.0",
24+
"karma-coffee-preprocessor": "^0.3.0",
25+
"karma-coverage": "^0.5.5",
2526
"karma-coveralls": "~0.1.4",
2627
"karma-firefox-launcher": "0.1.x",
27-
"karma-html2js-preprocessor": "0.1.x",
28-
"karma-jasmine": "0.1.x",
29-
"karma-junit-reporter": "0.2.x",
30-
"karma-phantomjs-launcher": "0.1.x",
31-
"karma-requirejs": "0.2.x",
32-
"karma-script-launcher": "0.1.x",
28+
"karma-html2js-preprocessor": "^0.1.0",
29+
"karma-jasmine": "^0.3.7",
30+
"karma-junit-reporter": "^0.4.0",
31+
"karma-phantomjs-launcher": "^1.0.0",
32+
"karma-requirejs": "^0.2.5",
33+
"karma-script-launcher": "^0.2.0",
3334
"load-grunt-tasks": "0.2.x",
3435
"requirejs": "2.1.x",
3536
"wiredep": "1.8.x"

test/sortable.e2e.callbacks.spec.js

+9-9
Original file line numberDiff line numberDiff line change
@@ -348,14 +348,14 @@ describe('uiSortable', function() {
348348
callbackContexts.stop = this;
349349
}
350350
};
351-
spyOn($rootScope.opts, 'helper').andCallThrough();
352-
spyOn($rootScope.opts, 'create').andCallThrough();
353-
spyOn($rootScope.opts, 'start').andCallThrough();
354-
spyOn($rootScope.opts, 'activate').andCallThrough();
355-
spyOn($rootScope.opts, 'beforeStop').andCallThrough();
356-
spyOn($rootScope.opts, 'update').andCallThrough();
357-
spyOn($rootScope.opts, 'deactivate').andCallThrough();
358-
spyOn($rootScope.opts, 'stop').andCallThrough();
351+
spyOn($rootScope.opts, 'helper').and.callThrough();
352+
spyOn($rootScope.opts, 'create').and.callThrough();
353+
spyOn($rootScope.opts, 'start').and.callThrough();
354+
spyOn($rootScope.opts, 'activate').and.callThrough();
355+
spyOn($rootScope.opts, 'beforeStop').and.callThrough();
356+
spyOn($rootScope.opts, 'update').and.callThrough();
357+
spyOn($rootScope.opts, 'deactivate').and.callThrough();
358+
spyOn($rootScope.opts, 'stop').and.callThrough();
359359
$rootScope.items = ['One', 'Two', 'Three'];
360360
element = $compile(''.concat(
361361
'<ul ui-sortable="opts" ng-model="items">',
@@ -410,7 +410,7 @@ describe('uiSortable', function() {
410410
$rootScope.opts = {
411411
start: function (e, ui) {
412412
uiItem = ui.item;
413-
spyOn(ui.item.sortable, '_destroy').andCallThrough();
413+
spyOn(ui.item.sortable, '_destroy').and.callThrough();
414414
uiItemSortable_Destroy = ui.item.sortable._destroy;
415415
},
416416
update: function(e, ui) {

test/sortable.e2e.multi.spec.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1064,7 +1064,7 @@ describe('uiSortable', function() {
10641064
connectWith: '.cross-sortable',
10651065
start: function (e, ui) {
10661066
uiItem = ui.item;
1067-
spyOn(ui.item.sortable, '_destroy').andCallThrough();
1067+
spyOn(ui.item.sortable, '_destroy').and.callThrough();
10681068
uiItemSortable_Destroy = ui.item.sortable._destroy;
10691069
},
10701070
update: function(e, ui) {

test/sortable.spec.js

+2-4
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,6 @@ describe('uiSortable', function() {
4949
mockJQliteFn.jquery = null;
5050
angular.element.fn = mockJQliteFn;
5151

52-
this.after(function () {
53-
angular.element.fn = oldAngularElementFn;
54-
});
55-
5652
var element;
5753
element = $compile('<ul ui-sortable><li ng-repeat="item in items" id="s-{{$index}}">{{ item }}</li></ul>')($rootScope);
5854
$rootScope.$apply(function() {
@@ -62,6 +58,8 @@ describe('uiSortable', function() {
6258
expect($log.error.logs.length).toEqual(1);
6359
expect($log.error.logs[0].length).toEqual(1);
6460
expect($log.error.logs[0][0]).toEqual('ui.sortable: jQuery should be included before AngularJS!');
61+
62+
angular.element.fn = oldAngularElementFn;
6563
});
6664
});
6765

0 commit comments

Comments
 (0)