Skip to content

Commit

Permalink
test(scroller): Removing element.on mock function.
Browse files Browse the repository at this point in the history
  • Loading branch information
Portugal, Marcelo authored and Portugal, Marcelo committed Dec 9, 2016
1 parent 530d079 commit e424b60
Showing 1 changed file with 30 additions and 30 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -32,37 +32,37 @@

beforeEach(function() {
spyOn(gridUtil, 'isTouchEnabled').and.returnValue(true);
preventDefaultSpy = jasmine.createSpy('preventDefault');
// preventDefaultSpy = jasmine.createSpy('preventDefault');

element.on.and.callFake(function(eventName, callback) {
switch (eventName) {
// case 'touchstart':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
// case 'touchmove':
// callback({
// type: eventName,
// touches: [true],
// preventDefault: preventDefaultSpy
// });
// break;
// case 'touchend':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
// case 'touchcancel':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
}
});
// element.on.and.callFake(function(eventName, callback) {
// switch (eventName) {
// case 'touchstart':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
// case 'touchmove':
// callback({
// type: eventName,
// touches: [true],
// preventDefault: preventDefaultSpy
// });
// break;
// case 'touchend':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
// case 'touchcancel':
// callback({
// type: eventName,
// touches: [true]
// });
// break;
// }
// });
uiGridScroller(element, scrollHandler);
});
it('should initialize uiGridScroller.initiated to NONE', function() {
Expand Down

0 comments on commit e424b60

Please sign in to comment.