diff options
Diffstat (limited to 'tests/core')
| -rw-r--r-- | tests/core/managers/pip3_spec.lua | 4 | ||||
| -rw-r--r-- | tests/core/spawn_spec.lua | 14 |
2 files changed, 17 insertions, 1 deletions
diff --git a/tests/core/managers/pip3_spec.lua b/tests/core/managers/pip3_spec.lua index adbda4ec..15a723d6 100644 --- a/tests/core/managers/pip3_spec.lua +++ b/tests/core/managers/pip3_spec.lua @@ -53,6 +53,7 @@ describe("pip3 manager", function() "supporting-package2", }, env = match.is_table(), + check_executable = false, }) end) ) @@ -113,6 +114,7 @@ describe("pip3 manager", function() match.tbl_containing { "--proxy", "http://localhost:8080" }, match.tbl_containing { "package" }, env = match.is_table(), + check_executable = false, }) end) ) @@ -170,6 +172,7 @@ describe("pip3 version check", function() "--format=json", cwd = "/tmp/install/dir", env = match.table(), + check_executable = false, }) assert.is_true(result:is_success()) assert.equals("1.3.0", result:get_or_nil()) @@ -208,6 +211,7 @@ describe("pip3 version check", function() "--format=json", cwd = "/tmp/install/dir", env = match.table(), + check_executable = false, }) assert.is_true(result:is_success()) assert.same({ diff --git a/tests/core/spawn_spec.lua b/tests/core/spawn_spec.lua index b3dfce35..c7b4f320 100644 --- a/tests/core/spawn_spec.lua +++ b/tests/core/spawn_spec.lua @@ -153,10 +153,22 @@ describe("async spawn", function() callback(false, 127) end) + local result = spawn.bash {} + assert.is_true(result:is_failure()) + assert.equals( + "spawn: bash failed with exit code 127. This is an error message for bash!", + tostring(result:err_or_nil()) + ) + end) + ) + + it( + "should skip checking executable", + async_test(function() local result = spawn.my_cmd {} assert.is_true(result:is_failure()) assert.equals( - "spawn: my_cmd failed with exit code 127. This is an error message for my_cmd!", + "spawn: my_cmd failed with no exit code. my_cmd is not executable", tostring(result:err_or_nil()) ) end) |
