todo/public/vendor/select2/tests/data/base-tests.js
Supan Adit Pratama 35d8715ab4 first commit
2020-06-23 11:40:37 +07:00

30 lines
667 B
JavaScript
Executable File
Vendored

module('Data adapters - Base');
var BaseData = require('select2/data/base');
var $ = require('jquery');
var Options = require('select2/options');
var options = new Options({});
test('current is required', function (assert) {
var data = new BaseData($('#qunit-fixture select'), options);
assert.throws(
function () {
data.current(function () {});
},
'current has no default implementation'
);
});
test('query is required', function (assert) {
var data = new BaseData($('#qunit-fixture select'), options);
assert.throws(
function () {
data.query({}, function () {});
},
'query has no default implementation'
);
});