Sha256: 82945f9aa197cb5e64643c80608d4e22f8d6c9c6866438e3e9e4db13de9135e2
Contents?: true
Size: 1.52 KB
Versions: 62
Compression:
Stored size: 1.52 KB
Contents
(function () { 'use strict'; describe('WORKAREA.contentBlocks', function () { describe('init', function () { beforeEach(function () { this.fixtures = fixture.load('content_block.html'); }); afterEach(function () { WORKAREA.takeover.close(); }); it('activates when clicked', function () { WORKAREA.contentBlocks.init($(this.fixtures)); $('.content-block').addClass('content-block--inactive'); $('.content-block__overlay').trigger('click'); expect(_.isEmpty('.content-block--active')).to.equal(false); }); }); describe('activateBlock', function() { it('activates the content block', function() { var $fixture = $(fixture.load('content_block.html')), $block = $('.content-block', $fixture).first(); WORKAREA.contentBlocks.activateBlock($block); expect(_.isEmpty($('.content-block--active'))).to.equal(false); }); }); describe('deactivateBlock', function() { it('deactivates the content block', function() { var $fixture = $(fixture.load('content_block.html')), $block = $('.content-block', $fixture).first(); WORKAREA.contentBlocks.deactivateBlock($block); expect(_.isEmpty($('.content-block--active'))).to.equal(true); }); }); }); }());
Version data entries
62 entries across 62 versions & 1 rubygems