summaryrefslogtreecommitdiff
path: root/tests/scripts/functions
diff options
context:
space:
mode:
authorPaul Smith <psmith@gnu.org>2005-06-27 01:01:07 +0000
committerPaul Smith <psmith@gnu.org>2005-06-27 01:01:07 +0000
commitda1b137e389365ddfb9d16b3d6761cf1a3986e0b (patch)
tree14a9a1f8b975eaae55a686ff2dc6d602c201b2aa /tests/scripts/functions
parentd6a7894d3a6bdb45def58b2fdfb0629233f4f38b (diff)
downloadgunmake-da1b137e389365ddfb9d16b3d6761cf1a3986e0b.tar.gz
Fix strerror() handling for systems which set ANSI_STRING.
Don't print errors if "include" is specified with no arguments. New test suite for the $(shell ...) function.
Diffstat (limited to 'tests/scripts/functions')
-rw-r--r--tests/scripts/functions/shell23
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/scripts/functions/shell b/tests/scripts/functions/shell
new file mode 100644
index 0000000..ecea4cf
--- /dev/null
+++ b/tests/scripts/functions/shell
@@ -0,0 +1,23 @@
+# -*-perl-*-
+
+$description = 'Test the $(shell ...) function.';
+
+$details = '';
+
+
+# Test shells inside rules.
+run_make_test('.PHONY: all
+all: ; @echo $(shell echo hi)
+','','hi');
+
+
+# Test shells inside exported environment variables.
+# This is the test that fails if we try to put make exported variables into
+# the environment for a $(shell ...) call.
+run_make_test('
+export HI = $(shell echo hi)
+.PHONY: all
+all: ; @echo $$HI
+','','hi');
+
+1;