uhr/test/test.js

22 lines
588 B
JavaScript
Raw Normal View History

suite('Bärneruhr', function () {
'use strict';
var assert = chai.assert;
test('create widget', function () {
var e = jQuery('#u');
var uhr = e.uhr('instance');
assert.isUndefined(uhr);
uhr = e.uhr();
assert.isNotNull(uhr);
assert.isDefined(uhr);
2014-07-04 01:08:39 +02:00
});
test('destroy widget', function() {
var e = jQuery('#u');
var uhr = e.uhr('instance');
assert.isNotNull(uhr);
assert.isDefined(uhr);
e.uhr('destroy');
uhr = e.uhr('instance');
assert.isUndefined(uhr);
});
});