Skip to content

Commit 0b0cc4e

Browse files
fix(tests): improve check to assert echo exists in path
1 parent 028b6d1 commit 0b0cc4e

File tree

1 file changed

+4
-1
lines changed
  • tests/run-make-fulldeps/hotplug_codegen_backend

1 file changed

+4
-1
lines changed

tests/run-make-fulldeps/hotplug_codegen_backend/Makefile

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,11 @@ include ../../run-make/tools.mk
66
# backends and that this external codegen backend is only included in the dep info if
77
# -Zbinary-dep-depinfo is used.
88

9+
REQUIRED := echo # This test requires `echo` to exist
10+
$(foreach bin,$(REQUIRED),\
11+
$(if $(shell command -v $(bin) 2> /dev/null),,$(error Error: Please install `$(bin)`)))
12+
913
all:
10-
/bin/echo || exit 0 # This test requires /bin/echo to exist
1114
$(RUSTC) the_backend.rs --crate-name the_backend --crate-type dylib \
1215
-o $(TMPDIR)/the_backend.dylib
1316

0 commit comments

Comments
 (0)