Print line number of wait timeout in presenter spec

This commit is contained in:
Max Brunsfeld 2016-02-22 16:31:06 -08:00
parent 989b546f1e
commit ea5500a124

View File

@ -91,7 +91,9 @@ describe "TextEditorPresenter", ->
expectNoStateUpdate = (presenter, fn) -> expectStateUpdatedToBe(false, presenter, fn)
waitsForStateToUpdate = (presenter, fn) ->
waitsFor "presenter state to update", 1000, (done) ->
line = new Error().stack.split('\n')[2].split(':')[1]
waitsFor "presenter state to update at line #{line}", 1000, (done) ->
disposable = presenter.onDidUpdateState ->
disposable.dispose()
process.nextTick(done)