Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit dea2e09

Browse files
committed
Use until to make test more readable
1 parent 6828bc1 commit dea2e09

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

test/controllers/commit-view-controller.test.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import path from 'path';
22
import fs from 'fs';
33

44
import etch from 'etch';
5+
import until from 'test-until';
56

67
import Commit from '../../lib/models/commit';
78

@@ -166,7 +167,7 @@ describe('CommitViewController', function() {
166167

167168
sinon.spy(controller.refs.commitView, 'update');
168169
editor.destroy();
169-
await assert.async.isTrue(controller.refs.commitView.update.called);
170+
await until(() => controller.refs.commitView.update.called);
170171
assert.equal(controller.refs.commitView.editor.getText(), 'message in box');
171172
assert.isTrue(controller.refs.commitView.props.deactivateCommitBox);
172173

0 commit comments

Comments
 (0)