Sha256: ae59c893bea723dacdf3425b2a8b8207e7e5080f7ca819df91ea629dde982e3e
Contents?: true
Size: 633 Bytes
Versions: 40
Compression:
Stored size: 633 Bytes
Contents
describe('Directive: stopEvent', function () { var element; beforeEach(module('Bastion.utils')); beforeEach(inject(function ($compile, $rootScope) { element = angular.element('<input type="text" stop-event="click"/>'); $compile(element)($rootScope); $rootScope.$digest(); })); it("stops propagation on the specified event", function () { var event = { type: 'click', stopPropagation: function () {} }; spyOn(event, 'stopPropagation'); element.trigger(event); expect(event.stopPropagation).toHaveBeenCalled(); }); });
Version data entries
40 entries across 40 versions & 1 rubygems