2017-10-13 14:43:58 +02:00
|
|
|
import { expect } from 'chai';
|
|
|
|
import WrappedSelect from './wrapped-select';
|
|
|
|
import { DEFAULT_CLASSNAMES, DEFAULT_CONFIG } from '../constants';
|
|
|
|
|
2017-10-29 19:56:24 +01:00
|
|
|
describe('components/wrappedSelect', () => {
|
2017-10-13 14:43:58 +02:00
|
|
|
let instance;
|
|
|
|
let choicesInstance;
|
|
|
|
let choicesElement;
|
|
|
|
|
|
|
|
beforeEach(() => {
|
|
|
|
choicesInstance = {
|
|
|
|
config: {
|
|
|
|
...DEFAULT_CONFIG,
|
|
|
|
},
|
|
|
|
};
|
|
|
|
choicesElement = document.createElement('select');
|
|
|
|
instance = new WrappedSelect(choicesInstance, choicesElement, DEFAULT_CLASSNAMES);
|
|
|
|
});
|
2017-12-18 13:06:38 +01:00
|
|
|
|
|
|
|
afterEach(() => {
|
|
|
|
document.body.innerHTML = '';
|
|
|
|
instance = null;
|
|
|
|
});
|
2017-10-13 14:43:58 +02:00
|
|
|
});
|