mirror of
https://github.com/videojs/video.js.git
synced 2024-12-06 10:47:19 +02:00
17 lines
395 B
JavaScript
17 lines
395 B
JavaScript
import extendFn from '../../src/js/extend.js';
|
|
|
|
q.module('extend.js');
|
|
|
|
test('should add implicit parent constructor call', function(){
|
|
var superCalled = false;
|
|
var Parent = function() {
|
|
superCalled = true;
|
|
};
|
|
var Child = extendFn(Parent, {
|
|
foo: 'bar'
|
|
});
|
|
var child = new Child();
|
|
ok(superCalled, 'super constructor called');
|
|
ok(child.foo, 'child properties set');
|
|
});
|