diff options
author | rillig <rillig@pkgsrc.org> | 2020-08-04 21:35:01 +0000 |
---|---|---|
committer | rillig <rillig@pkgsrc.org> | 2020-08-04 21:35:01 +0000 |
commit | 401464832eb95f6f2da96dd948a250942920c514 (patch) | |
tree | 730096a9027bc44ec62b76941a3156c441ecdd79 /regress | |
parent | 9c69ecafa08757fb15062b97a85259d65c471d9d (diff) | |
download | pkgsrc-401464832eb95f6f2da96dd948a250942920c514.tar.gz |
regress/infra-unittests: add test for help, topic followed by comma
Diffstat (limited to 'regress')
-rw-r--r-- | regress/infra-unittests/help.sh | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/regress/infra-unittests/help.sh b/regress/infra-unittests/help.sh index be8a43eac1f..09b8d1658b6 100644 --- a/regress/infra-unittests/help.sh +++ b/regress/infra-unittests/help.sh @@ -1,5 +1,5 @@ #! /bin/sh -# $NetBSD: help.sh,v 1.5 2020/05/16 20:22:41 rillig Exp $ +# $NetBSD: help.sh,v 1.6 2020/08/04 21:35:01 rillig Exp $ # # Test cases for "bmake help", mainly implemented in mk/help/help.awk. # @@ -142,3 +142,24 @@ if test_case_begin 'commented variables with continuation lines'; then test_case_end fi + + +if test_case_begin 'variable name followed by comma'; then + + create_file 'fetch.mk' <<-EOF + # + # FETCH_USE_IPV4_ONLY, if defined, will ... + # ... + # ... + EOF + + TOPIC='fetch_use_ipv4_only' awk -f "$pkgsrcdir/mk/help/help.awk" \ + 'fetch.mk' >'out' + + assert_that 'out' --file-is-lines \ + 'No help found for fetch_use_ipv4_only, but it appears in:' \ + '' \ + 'fetch.mk' + + test_case_end +fi |