From e9060dda0dd04e99666ff29efe459ebc7d7c65a7 Mon Sep 17 00:00:00 2001 From: yiminghe Date: Sat, 5 Dec 2015 03:26:32 +0800 Subject: lint --- tests/Header.spec.jsx | 133 ++++++++++++++++++++++------------------------ tests/Select.spec.jsx | 133 ++++++++++++++++++++++------------------------ tests/TimePicker.spec.jsx | 101 ++++++++++++++++------------------- 3 files changed, 175 insertions(+), 192 deletions(-) (limited to 'tests') diff --git a/tests/Header.spec.jsx b/tests/Header.spec.jsx index e574d38..cc8f954 100644 --- a/tests/Header.spec.jsx +++ b/tests/Header.spec.jsx @@ -3,22 +3,28 @@ import React from 'react'; import TimePicker from '../src/TimePicker'; import TestUtils from 'react-addons-test-utils'; -var Simulate = TestUtils.Simulate; +const Simulate = TestUtils.Simulate; import expect from 'expect.js'; import async from 'async'; import {KeyCode} from 'rc-util'; import DateTimeFormat from 'gregorian-calendar-format'; -import GregorianCalendar from 'gregorian-calendar'; import zhCn from 'gregorian-calendar/lib/locale/zh_CN'; import TimePickerLocale from '../src/locale/zh_CN'; -describe('Header', function () { - var container; +function formatTime(time, formatter) { + return formatter.parse(time, { + locale: zhCn, + obeyCount: true, + }); +} + +describe('Header', () => { + let container; function renderPicker(props) { - var showSecond = true; - var formatter = new DateTimeFormat('HH:mm:ss'); + const showSecond = true; + const formatter = new DateTimeFormat('HH:mm:ss'); return ReactDOM.render( , container); } - function formatTime(time, formatter) { - return formatter.parse(time, { - locale: zhCn, - obeyCount: true, - }); - } - - beforeEach(function () { + beforeEach(() => { container = document.createElement('div'); document.body.appendChild(container); }); - afterEach(function () { + afterEach(() => { ReactDOM.unmountComponentAtNode(container); document.body.removeChild(container); }); - describe('input to change value', function () { - it('input correctly', function (done) { - var picker = renderPicker(); + describe('input to change value', () => { + it('input correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; expect(header).to.be.ok(); @@ -66,26 +65,26 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '12:34:56'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('12:34:56'); expect(ReactDOM.findDOMNode(input).value).to.be('12:34:56'); next(); - }], function () { + }], () => { done(); }); }); - it('carry correctly', function (done) { - var picker = renderPicker(); + it('carry correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; expect(header).to.be.ok(); @@ -95,7 +94,7 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '33:44:55'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('09:44:55'); expect(ReactDOM.findDOMNode(input).value).to.be('09:44:55'); @@ -103,7 +102,7 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '10:90:30'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('11:30:30'); expect(ReactDOM.findDOMNode(input).value).to.be('11:30:30'); @@ -111,26 +110,26 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '34:56:78'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('10:57:18'); expect(ReactDOM.findDOMNode(input).value).to.be('10:57:18'); next(); - }], function () { + }], () => { done(); }); }); - it('check correctly', function (done) { - var picker = renderPicker(); + it('check correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; expect(header).to.be.ok(); @@ -140,7 +139,7 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '3:34:56'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('3:34:56'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); @@ -149,7 +148,7 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '13:3:56'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('13:3:56'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); @@ -158,39 +157,38 @@ describe('Header', function () { ReactDOM.findDOMNode(header).value = '13:34:5'; Simulate.change(header); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); expect(ReactDOM.findDOMNode(header).value).to.be('13:34:5'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); expect(ReactDOM.findDOMNode(header).className).to.contain('rc-time-picker-panel-input-invalid'); next(); - }], function () { + }], () => { done(); }); }); - }); - describe('other operations', function () { - it('clear correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { + describe('other operations', () => { + it('clear correctly', (done) => { + let change; + const picker = renderPicker({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; - var clearButton = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-clear-btn')[0]; + const clearButton = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-clear-btn')[0]; expect(header).to.be.ok(); expect(clearButton).to.be.ok(); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:03'); @@ -198,29 +196,29 @@ describe('Header', function () { Simulate.mouseDown(clearButton); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(false); expect(change).to.be(null); expect(ReactDOM.findDOMNode(header).value).to.be(''); expect(ReactDOM.findDOMNode(input).value).to.be(''); next(); - }], function () { + }], () => { done(); }); }); - it('exit correctly', function (done) { - var picker = renderPicker(); + it('exit correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; expect(header).to.be.ok(); @@ -228,19 +226,18 @@ describe('Header', function () { expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); Simulate.keyDown(ReactDOM.findDOMNode(header), { - keyCode: KeyCode.ESC + keyCode: KeyCode.ESC, }); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(false); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:03'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); next(); - }], function () { + }], () => { done(); }); }); - }); }); diff --git a/tests/Select.spec.jsx b/tests/Select.spec.jsx index 036a0f9..7e53c31 100644 --- a/tests/Select.spec.jsx +++ b/tests/Select.spec.jsx @@ -3,22 +3,26 @@ import React from 'react'; import TimePicker from '../src/TimePicker'; import TestUtils from 'react-addons-test-utils'; -var Simulate = TestUtils.Simulate; +const Simulate = TestUtils.Simulate; import expect from 'expect.js'; import async from 'async'; -import {KeyCode} from 'rc-util'; - import DateTimeFormat from 'gregorian-calendar-format'; -import GregorianCalendar from 'gregorian-calendar'; import zhCn from 'gregorian-calendar/lib/locale/zh_CN'; import TimePickerLocale from '../src/locale/zh_CN'; -describe('Select', function () { - var container; +function formatTime(time, formatter) { + return formatter.parse(time, { + locale: zhCn, + obeyCount: true, + }); +} + +describe('Select', () => { + let container; function renderPicker(props) { - var showSecond = true; - var formatter = new DateTimeFormat('HH:mm:ss'); + const showSecond = true; + const formatter = new DateTimeFormat('HH:mm:ss'); return ReactDOM.render( , container); } - function formatTime(time, formatter) { - return formatter.parse(time, { - locale: zhCn, - obeyCount: true, - }); - } - - beforeEach(function () { + beforeEach(() => { container = document.createElement('div'); document.body.appendChild(container); }); - afterEach(function () { + afterEach(() => { ReactDOM.unmountComponentAtNode(container); document.body.removeChild(container); }); - describe('select number', function () { - - it('select number correctly', function (done) { - var picker = renderPicker(); + describe('select number', () => { + it('select number correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var selector; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let selector; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select'); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(selector.length).to.be(3); next(); - }], function () { + }], () => { done(); }); }); - }); - describe('select to change value', function () { - - it('hour correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { + describe('select to change value', () => { + it('hour correctly', (done) => { + let change; + const picker = renderPicker({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; - var selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[0]; - var option = selector.getElementsByTagName('li')[19]; + const selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[0]; + const option = selector.getElementsByTagName('li')[19]; expect(header).to.be.ok(); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:03'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); Simulate.click(option); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(change).to.be.ok(); expect(change.getHourOfDay()).to.be(19); expect(ReactDOM.findDOMNode(header).value).to.be('19:02:03'); @@ -111,38 +105,38 @@ describe('Select', function () { expect(picker.state.open).to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); - it('minute correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { + it('minute correctly', (done) => { + let change; + const picker = renderPicker({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; - var selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[1]; - var option = selector.getElementsByTagName('li')[19]; + const selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[1]; + const option = selector.getElementsByTagName('li')[19]; expect(header).to.be.ok(); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:03'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); Simulate.click(option); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(change).to.be.ok(); expect(change.getMinutes()).to.be(19); expect(ReactDOM.findDOMNode(header).value).to.be('01:19:03'); @@ -150,38 +144,38 @@ describe('Select', function () { expect(picker.state.open).to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); - it('second correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { + it('second correctly', (done) => { + let change; + const picker = renderPicker({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - var header; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + let header; + async.series([(next) => { expect(picker.state.open).to.be(false); Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(picker.state.open).to.be(true); header = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-input')[0]; - var selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[2]; - var option = selector.getElementsByTagName('li')[19]; + const selector = TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-select')[2]; + const option = selector.getElementsByTagName('li')[19]; expect(header).to.be.ok(); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:03'); expect(ReactDOM.findDOMNode(input).value).to.be('01:02:03'); Simulate.click(option); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(change).to.be.ok(); expect(change.getSeconds()).to.be(19); expect(ReactDOM.findDOMNode(header).value).to.be('01:02:19'); @@ -189,10 +183,9 @@ describe('Select', function () { expect(picker.state.open).to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); - }); }); diff --git a/tests/TimePicker.spec.jsx b/tests/TimePicker.spec.jsx index 5bd056e..95a1fd1 100644 --- a/tests/TimePicker.spec.jsx +++ b/tests/TimePicker.spec.jsx @@ -3,21 +3,27 @@ import React from 'react'; import TimePicker from '../src/TimePicker'; import TestUtils from 'react-addons-test-utils'; -var Simulate = TestUtils.Simulate; +const Simulate = TestUtils.Simulate; import expect from 'expect.js'; import async from 'async'; import DateTimeFormat from 'gregorian-calendar-format'; -import GregorianCalendar from 'gregorian-calendar'; import zhCn from 'gregorian-calendar/lib/locale/zh_CN'; import TimePickerLocale from '../src/locale/zh_CN'; -describe('TimePicker', function () { - var container; +function formatTime(time, formatter) { + return formatter.parse(time, { + locale: zhCn, + obeyCount: true, + }); +} + +describe('TimePicker', () => { + let container; function renderPicker(props) { - var showSecond = true; - var formatter = new DateTimeFormat('HH:mm:ss'); + const showSecond = true; + const formatter = new DateTimeFormat('HH:mm:ss'); return ReactDOM.render( , container); } - function formatTime(time, formatter) { - return formatter.parse(time, { - locale: zhCn, - obeyCount: true, - }); - } - - beforeEach(function () { + beforeEach(() => { container = document.createElement('div'); document.body.appendChild(container); }); - afterEach(function () { + afterEach(() => { ReactDOM.unmountComponentAtNode(container); document.body.removeChild(container); }); - describe('render panel to body', function () { - it('popup correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { + describe('render panel to body', () => { + it('popup correctly', (done) => { + let change; + const picker = renderPicker({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; expect(ReactDOM.findDOMNode(input).value).to.be('12:57:58'); - async.series([function (next) { + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-inner')[0]).to.be.ok(); expect(picker.state.open).to.be(true); - var hour = TestUtils.scryRenderedDOMComponentsWithTag(picker.panelInstance, 'li')[1]; + const hour = TestUtils.scryRenderedDOMComponentsWithTag(picker.panelInstance, 'li')[1]; Simulate.click(hour); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(change).to.be.ok(); expect(change.getHourOfDay()).to.be(1); expect(change.getMinutes()).to.be(57); @@ -88,24 +87,19 @@ describe('TimePicker', function () { expect(ReactDOM.findDOMNode(input).value).to.be('01:57:58'); expect(picker.state.open).to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); - it('destroy correctly', function (done) { - var change; - var picker = renderPicker({ - onChange: function (v) { - change = v; - } - }); + it('destroy correctly', (done) => { + const picker = renderPicker(); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; - async.series([function (next) { + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-panel-inner')[0]).not.to.be.ok(); expect(picker.state.open).to.be(true); if (document.querySelectorAll) { @@ -114,49 +108,48 @@ describe('TimePicker', function () { expect(TestUtils.scryRenderedDOMComponentsWithTag(picker.panelInstance, 'li')[0]).to.be.ok(); ReactDOM.unmountComponentAtNode(container); setTimeout(next, 100); - }, function (next) { + }, (next) => { if (document.querySelectorAll) { expect(document.querySelectorAll('.rc-time-picker').length).to.be(0); } expect(picker.panelInstance).not.to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); }); - describe('render panel to body (without seconds)', function () { - it('popup correctly', function (done) { - var change; - var picker = renderPickerWithoutSeconds({ - onChange: function (v) { + describe('render panel to body (without seconds)', () => { + it('popup correctly', (done) => { + let change; + const picker = renderPickerWithoutSeconds({ + onChange(v) { change = v; - } + }, }); expect(picker.state.open).not.to.be.ok(); - var input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; + const input = TestUtils.scryRenderedDOMComponentsWithClass(picker, 'rc-time-picker-input')[0]; expect(ReactDOM.findDOMNode(input).value).to.be('08:24'); - async.series([function (next) { + async.series([(next) => { Simulate.click(input); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(TestUtils.scryRenderedDOMComponentsWithClass(picker.panelInstance, 'rc-time-picker-panel-inner')[0]).to.be.ok(); expect(picker.state.open).to.be(true); - var hour = TestUtils.scryRenderedDOMComponentsWithTag(picker.panelInstance, 'li')[1]; + const hour = TestUtils.scryRenderedDOMComponentsWithTag(picker.panelInstance, 'li')[1]; Simulate.click(hour); setTimeout(next, 100); - }, function (next) { + }, (next) => { expect(change).to.be.ok(); expect(change.getHourOfDay()).to.be(1); expect(change.getMinutes()).to.be(24); expect(ReactDOM.findDOMNode(input).value).to.be('01:24'); expect(picker.state.open).to.be.ok(); next(); - }], function () { + }], () => { done(); }); }); }); - }); -- cgit v1.2.3