plugin = new Foundation.Tooltip($html, {});
plugin.$element.should.have.attr('aria-describedby', plugin.template.attr('id'));
+ plugin.template.should.have.attr('aria-hidden', 'true');
plugin.template.should.have.attr('role', 'tooltip');
});
plugin.show();
plugin.template.should.be.visible;
+ plugin.template.should.have.attr('aria-hidden', 'false');
});
it('fires show.zf.tooltip event', function(done) {
plugin.hide();
plugin.template.should.be.hidden;
+ plugin.template.should.have.attr('aria-hidden', 'true');
});
it('fires hide.zf.tooltip event', function(done) {
plugin.toggle();
plugin.template.should.be.visible;
+ plugin.template.should.have.attr('aria-hidden', 'false');
});
it('hides a visible tooltip', function() {
$html = $(template).appendTo('body');
plugin.toggle();
plugin.template.should.be.hidden;
+ plugin.template.should.have.attr('aria-hidden', 'true');
});
});