diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2019-09-06 18:16:57 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-06 18:16:57 -0700 |
commit | 158b78062e9daa65203b4591dae733dd6c11ad2c (patch) | |
tree | e6988da22f16062b57d50daeda084bcc489a6a1d /test/functional/provider/ruby_spec.lua | |
parent | 638f2b6dee7439de303bea12dec80240617e8034 (diff) | |
parent | 7e1c9598617a140e40a0a22676c0631294617246 (diff) | |
download | rneovim-158b78062e9daa65203b4591dae733dd6c11ad2c.tar.gz rneovim-158b78062e9daa65203b4591dae733dd6c11ad2c.tar.bz2 rneovim-158b78062e9daa65203b4591dae733dd6c11ad2c.zip |
Merge #10932 'test: Eliminate expect_err'
Diffstat (limited to 'test/functional/provider/ruby_spec.lua')
-rw-r--r-- | test/functional/provider/ruby_spec.lua | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/functional/provider/ruby_spec.lua b/test/functional/provider/ruby_spec.lua index 72802db3c9..d20adde2ef 100644 --- a/test/functional/provider/ruby_spec.lua +++ b/test/functional/provider/ruby_spec.lua @@ -6,22 +6,23 @@ local curbufmeths = helpers.curbufmeths local eq = helpers.eq local eval = helpers.eval local expect = helpers.expect -local expect_err = helpers.expect_err local feed = helpers.feed local feed_command = helpers.feed_command local funcs = helpers.funcs local insert = helpers.insert local meths = helpers.meths local missing_provider = helpers.missing_provider +local matches = helpers.matches local write_file = helpers.write_file +local pcall_err = helpers.pcall_err do clear() if missing_provider('ruby') then it(':ruby reports E319 if provider is missing', function() local expected = [[Vim%(ruby.*%):E319: No "ruby" provider found.*]] - expect_err(expected, command, 'ruby puts "foo"') - expect_err(expected, command, 'rubyfile foo') + matches(expected, pcall_err(command, 'ruby puts "foo"')) + matches(expected, pcall_err(command, 'rubyfile foo')) end) pending("Missing neovim RubyGem.", function() end) return |