Skip to content

Commit 968a4b9

Browse files
authored
fix(tests): switch to macos compatible commands (#375)
1 parent 9c3239b commit 968a4b9

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

tests/plenary/job_spec.lua

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -95,9 +95,9 @@ describe("Job", function()
9595
it("should return last line when there is ending newline", function()
9696
local results = {}
9797
local job = Job:new {
98-
command = "echo",
98+
command = "printf",
9999

100-
args = { "-e", "test1\ntest2" },
100+
args = { "test1\ntest2\n" },
101101

102102
on_stdout = function(_, data)
103103
table.insert(results, data)
@@ -113,9 +113,9 @@ describe("Job", function()
113113
pending("should return last line when there is no ending newline", function()
114114
local results = {}
115115
local job = Job:new {
116-
command = "echo",
116+
command = "printf",
117117

118-
args = { "-en", "test1\ntest2" },
118+
args = { "test1\ntest2" },
119119

120120
on_stdout = function(_, data)
121121
table.insert(results, data)
@@ -277,11 +277,12 @@ describe("Job", function()
277277
end)
278278

279279
it("should match larger systemlist", function()
280-
local results = vim.fn.systemlist "find"
280+
local results = vim.fn.systemlist "find ."
281281
local stdout_results = {}
282282

283283
local job = Job:new {
284284
command = "find",
285+
args = { "." },
285286

286287
on_stdout = function(_, line)
287288
table.insert(stdout_results, line)

0 commit comments

Comments
 (0)