[Housekeeping] Close system port when jobs are cancelled (#182)
* Created a test setup that works * Refactored test setup into real-world fixes
This commit is contained in:
@@ -3,6 +3,12 @@ defmodule Pinchflat.Utils.CliUtilsTest do
|
||||
|
||||
alias Pinchflat.Utils.CliUtils
|
||||
|
||||
describe "wrap_cmd/3" do
|
||||
test "delegates to System.cmd/3" do
|
||||
assert {"output\n", 0} = CliUtils.wrap_cmd("echo", ["output"])
|
||||
end
|
||||
end
|
||||
|
||||
describe "parse_options/1" do
|
||||
test "it converts symbol k-v arg keys to kebab case" do
|
||||
assert ["--buffer-size", "1024"] = CliUtils.parse_options(buffer_size: 1024)
|
||||
|
||||
Reference in New Issue
Block a user