xref: /freebsd/contrib/bmake/unit-tests/varmod-to-upper.mk (revision 19261079b74319502c6ffa1249920079f0f69a72)
1# $NetBSD: varmod-to-upper.mk,v 1.5 2020/10/24 08:46:08 rillig Exp $
2#
3# Tests for the :tu variable modifier, which returns the words in the
4# variable value, converted to uppercase.
5
6.if ${:UUPPER:tu} != "UPPER"
7.  error
8.endif
9
10.if ${:Ulower:tu} != "LOWER"
11.  error
12.endif
13
14.if ${:UMixeD case.:tu} != "MIXED CASE."
15.  error
16.endif
17
18# The :tu and :tl modifiers operate on the variable value as a single string,
19# not as a list of words. Therefore, the adjacent spaces are preserved.
20mod-tu-space:
21	@echo $@: ${a   b:L:tu:Q}
22