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

Version Path
bastion-6.1.23 test/utils/stop-event.directive.test.js
bastion-6.1.22 test/utils/stop-event.directive.test.js
bastion-6.1.21 test/utils/stop-event.directive.test.js
bastion-6.1.20 test/utils/stop-event.directive.test.js
bastion-6.1.19 test/utils/stop-event.directive.test.js
bastion-6.1.18 test/utils/stop-event.directive.test.js
bastion-6.1.17 test/utils/stop-event.directive.test.js
bastion-6.1.16 test/utils/stop-event.directive.test.js
bastion-6.1.15 test/utils/stop-event.directive.test.js
bastion-6.1.14 test/utils/stop-event.directive.test.js
bastion-6.1.13 test/utils/stop-event.directive.test.js
bastion-6.1.12 test/utils/stop-event.directive.test.js
bastion-6.1.11 test/utils/stop-event.directive.test.js
bastion-6.1.10 test/utils/stop-event.directive.test.js
bastion-6.1.9 test/utils/stop-event.directive.test.js
bastion-6.1.8 test/utils/stop-event.directive.test.js
bastion-6.1.7 test/utils/stop-event.directive.test.js
bastion-6.1.6 test/utils/stop-event.directive.test.js
bastion-6.1.5 test/utils/stop-event.directive.test.js
bastion-6.1.4 test/utils/stop-event.directive.test.js