diff options
author | John MacFarlane <jgm@berkeley.edu> | 2018-05-08 12:28:12 -0700 |
---|---|---|
committer | John MacFarlane <jgm@berkeley.edu> | 2018-05-08 12:28:12 -0700 |
commit | 9f2af30c066d4d821237532b1dea3c8f3e7fac7b (patch) | |
tree | 48b3103e7f8c15a5899f19a73822721da3f33e07 /test/lua | |
parent | fa4f3c5c17ac0a832aea8933e5e723b9f40239c6 (diff) | |
download | pandoc-9f2af30c066d4d821237532b1dea3c8f3e7fac7b.tar.gz |
More adjustments to test-pandoc-utils.lua.
We need to find something that will work on windows.
Diffstat (limited to 'test/lua')
-rw-r--r-- | test/lua/test-pandoc-utils.lua | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/test/lua/test-pandoc-utils.lua b/test/lua/test-pandoc-utils.lua index f0040062e..4d736d2d5 100644 --- a/test/lua/test-pandoc-utils.lua +++ b/test/lua/test-pandoc-utils.lua @@ -38,7 +38,7 @@ end function test_pipe () if os_is_windows() then - local pipe_result = pandoc.pipe('echo', {}, 'hi') + local pipe_result = pandoc.pipe('find', {'hi'}, 'hi') return pipe_result == 'hi\n' or pipe_result == 'hi' else local pipe_result = pandoc.pipe('tr', {'a', 'b'}, 'abc') @@ -48,11 +48,10 @@ end function test_failing_pipe () if os_is_windows() then - local res, err = pcall(pandoc.pipe, 'cd', {}, 'NoNExistEnt') + local res, err = pcall(pandoc.pipe, 'find', {'/a'}, 'hi') return not res and - err.command == 'cd' and - err.error_code == 1 and - err.output == '' + err.command == 'find' and + err.error_code ~= 0 else local res, err = pcall(pandoc.pipe, 'false', {}, 'abc') return not res and |