From e129607988b88719935bc4af517e7ee2689f5871 Mon Sep 17 00:00:00 2001 From: ZyX Date: Wed, 26 Jul 2017 22:04:39 +0300 Subject: [PATCH] functests: Replace wait() with nvim_async --- test/functional/eval/input_spec.lua | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/test/functional/eval/input_spec.lua b/test/functional/eval/input_spec.lua index 0571043efe..cfb91983c1 100644 --- a/test/functional/eval/input_spec.lua +++ b/test/functional/eval/input_spec.lua @@ -2,13 +2,13 @@ local helpers = require('test.functional.helpers')(after_each) local Screen = require('test.functional.ui.screen') local eq = helpers.eq -local wait = helpers.wait local feed = helpers.feed local meths = helpers.meths local clear = helpers.clear local source = helpers.source local command = helpers.command local exc_exec = helpers.exc_exec +local nvim_async = helpers.nvim_async local screen @@ -229,16 +229,16 @@ describe('input()', function() exc_exec('call input("prompt> ", "default", "file", "extra")')) end) it('supports highlighting', function() - feed([[:call input({"highlight": "RainBowParens"})]]) - wait() + nvim_async('command', 'call input({"highlight": "RainBowParens"})') feed('(())') screen:expect([[ - {EOB:~ }| - {EOB:~ }| - {EOB:~ }| | + {EOB:~ }| + {EOB:~ }| + {EOB:~ }| {RBP1:(}{RBP2:()}{RBP1:)}^ | ]]) + feed('') end) end) describe('inputdialog()', function() @@ -408,15 +408,15 @@ describe('inputdialog()', function() exc_exec('call inputdialog("prompt> ", "default", "file", "extra")')) end) it('supports highlighting', function() - feed([[:call inputdialog({"highlight": "RainBowParens"})]]) - wait() + nvim_async('command', 'call inputdialog({"highlight": "RainBowParens"})') feed('(())') screen:expect([[ - {EOB:~ }| - {EOB:~ }| - {EOB:~ }| | + {EOB:~ }| + {EOB:~ }| + {EOB:~ }| {RBP1:(}{RBP2:()}{RBP1:)}^ | ]]) + feed('') end) end)