test spec

pull/163/head
ray-x 2 years ago
parent 6108dc9ea1
commit 7102361efd

@ -61,7 +61,7 @@ describe("should run test file", function()
vim.fn.setpos(".", { 0, 5, 11, 0 })
local cmd = require("go.gotest").test_file()
eq({ "go", "test", "-v", "-run", [[Test_branch\|TestBranch]], "./lua/tests/fixtures/coverage" }, cmd)
eq({ "go", "test", "-v", "-run", [['Test_branch|TestBranch']], "lua/tests/fixtures/coverage" }, cmd)
end)
end)
@ -84,7 +84,7 @@ describe("should run test file with flags", function()
vim.fn.setpos(".", { 0, 5, 11, 0 })
local cmd = require("go.gotest").test_file("-t", "tag1")
eq({ "go", "test", "-tags=tag1", "-v", "-run", [[Test_branch\|TestBranch]], "./lua/tests/fixtures/coverage" }, cmd)
eq({ "go", "test", "-tags=tag1", "-v", "-run", [['Test_branch|TestBranch']], "lua/tests/fixtures/coverage" }, cmd)
end)
end)
@ -183,8 +183,8 @@ describe("should run test file with flags inside file", function()
"-tags=tag1,integration,unit",
"-v",
"-run",
"TestTag",
"./lua/tests/fixtures/coverage",
"'TestTag'",
"lua/tests/fixtures/coverage",
},
cmd
)

Loading…
Cancel
Save