mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-26 05:03:09 +00:00
Merge pull request #30224 from tmrts/util-exec/fix-dependency
Automatic merge from submit-queue pkg/util/exec: don't specify paths for echo `ex.Command()` already searches the binary in PATH, no need to manually specify it as `/bin/echo`. `pkg/util/exec` tests fail in non-conventional environments due to this (e.g. NixOS).
This commit is contained in:
commit
c4f48509a8
@ -64,7 +64,7 @@ func TestExecutorNoArgs(t *testing.T) {
|
|||||||
func TestExecutorWithArgs(t *testing.T) {
|
func TestExecutorWithArgs(t *testing.T) {
|
||||||
ex := New()
|
ex := New()
|
||||||
|
|
||||||
cmd := ex.Command("/bin/echo", "stdout")
|
cmd := ex.Command("echo", "stdout")
|
||||||
out, err := cmd.CombinedOutput()
|
out, err := cmd.CombinedOutput()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Errorf("expected success, got %+v", err)
|
t.Errorf("expected success, got %+v", err)
|
||||||
|
Loading…
Reference in New Issue
Block a user