mirror of
https://github.com/videojs/video.js.git
synced 2025-07-17 01:42:41 +02:00
Major rewrite to support Google Closure Compiler Advanced Optimization.
Still in process.
This commit is contained in:
@ -3,7 +3,7 @@ module("Component");
|
||||
test('should create an element', function(){
|
||||
var comp = new _V_.Component({}, {});
|
||||
|
||||
ok(comp.el.nodeName);
|
||||
ok(comp.getEl().nodeName);
|
||||
});
|
||||
|
||||
test('should init child coponents from options', function(){
|
||||
@ -16,6 +16,18 @@ test('should init child coponents from options', function(){
|
||||
ok(comp.el.childNodes.length === 1);
|
||||
});
|
||||
|
||||
test('should add a child component', function(){
|
||||
var comp = new _V_.Component({});
|
||||
|
||||
comp.addChild("Component");
|
||||
|
||||
ok(comp.el.childNodes.length === 1);
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
test('should show and hide an element', function(){
|
||||
var comp = new _V_.Component({}, {});
|
||||
|
||||
@ -64,4 +76,4 @@ test('should trigger a listener once using one()', function(){
|
||||
comp.one('test-event', testListener);
|
||||
comp.trigger('test-event');
|
||||
comp.trigger('test-event');
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user