diff --git a/tests/usr.bin/tr/t_basic.sh b/tests/usr.bin/tr/t_basic.sh index 70bd2681d5c8..4515d114a800 100644 --- a/tests/usr.bin/tr/t_basic.sh +++ b/tests/usr.bin/tr/t_basic.sh @@ -1,4 +1,4 @@ -# $NetBSD: t_basic.sh,v 1.2 2013/08/11 00:29:21 dholland Exp $ +# $NetBSD: t_basic.sh,v 1.3 2013/08/11 01:50:02 dholland Exp $ # # Copyright (c) 2013 The NetBSD Foundation, Inc. # All rights reserved. @@ -57,6 +57,14 @@ dopt_body() { atf_check -o inline:'splice' -x '(echo spl; echo ice) | tr -d '"'\n'" atf_check -o inline:'splice' -x '(echo spl; echo ice) | tr -d '"'\012'" + # see if escape codes work when followed by other things + atf_check -o inline:'slice' -x '(echo spl; echo ice) | tr -d '"'\n'p" + atf_check -o inline:'slice' -x '(echo spl; echo ice) | tr -d '"'\012'p" + + # see if the [=x=] syntax works + atf_check -o inline:'abde\n' -x 'echo abcde | tr -d '"'[=c=]'" + atf_check -o inline:'bde\n' -x 'echo abcde | tr -d '"'[=c=]'a" + # make sure 0 works # (ignore stderr as dd blabbers to it) atf_check -e ignore -o inline:'ab\n' \