19796333 GNU getopt could use some tests
authorRich Burridge <rich.burridge@oracle.com>
Fri, 10 Oct 2014 14:52:24 -0700
changeset 2145 bdf83a99948d
parent 2144 96440b7aa33e
child 2146 35178fc229b5
19796333 GNU getopt could use some tests
components/getopt/Makefile
--- a/components/getopt/Makefile	Thu Oct 09 18:23:12 2014 -0700
+++ b/components/getopt/Makefile	Fri Oct 10 14:52:24 2014 -0700
@@ -56,6 +56,15 @@
 COMPONENT_POST_UNPACK_ACTION= \
 	$(RM) $(COMPONENT_SRC)/gnu/*.o
 
+# The getopt source directory contains bash and tcsh getopt example scripts.
+TEST_ARGS = -a par1 'another arg' --c-long 'wow\!*\?' -cmore -b " very long "
+COMPONENT_TEST_ENV +=		PATH=$(BUILD_DIR_$(BITS)):$(PATH)
+COMPONENT_TEST_DIR =		$(SOURCE_DIR)
+COMPONENT_TEST_CMD =		getopt-parse.bash $(TEST_ARGS); \
+				$(ENV) $(COMPONENT_TEST_ENV) \
+				getopt-parse.tcsh $(TEST_ARGS)
+COMPONENT_TEST_TARGETS =
+
 ASLR_MODE = $(ASLR_ENABLE)
 
 # common targets
@@ -63,7 +72,7 @@
 
 install:	$(INSTALL_64)
 
-test:		$(NO_TESTS)
+test:		$(TEST_64)
 
 BUILD_PKG_DEPENDENCIES =	$(BUILD_TOOLS)