diff options
author | 2016-04-10 15:00:03 +0000 | |
---|---|---|
committer | 2016-04-10 15:00:03 +0000 | |
commit | 196a64608fda9506475cd396cf8de16c118892c1 (patch) | |
tree | 89693d676430ab5d386fbb8a5de4399435987fd5 | |
parent | remove an uneeded include (diff) | |
download | wireguard-openbsd-196a64608fda9506475cd396cf8de16c118892c1.tar.xz wireguard-openbsd-196a64608fda9506475cd396cf8de16c118892c1.zip |
Simple regression tests for rev(1), including UTF-8.
The program will soon be fixed by martijn@.
-rw-r--r-- | regress/usr.bin/Makefile | 4 | ||||
-rw-r--r-- | regress/usr.bin/rev/Makefile | 11 | ||||
-rw-r--r-- | regress/usr.bin/rev/exp.ascii.txt | 8 | ||||
-rw-r--r-- | regress/usr.bin/rev/exp.utf8.txt | 8 | ||||
-rw-r--r-- | regress/usr.bin/rev/in.txt | 8 |
5 files changed, 37 insertions, 2 deletions
diff --git a/regress/usr.bin/Makefile b/regress/usr.bin/Makefile index 4b7337b33ea..8445b346bf7 100644 --- a/regress/usr.bin/Makefile +++ b/regress/usr.bin/Makefile @@ -1,8 +1,8 @@ -# $OpenBSD: Makefile,v 1.33 2015/12/06 18:42:12 schwarze Exp $ +# $OpenBSD: Makefile,v 1.34 2016/04/10 15:00:03 schwarze Exp $ # $NetBSD: Makefile,v 1.1 1997/12/30 23:27:11 cgd Exp $ SUBDIR+= basename bc dc diff diff3 dirname doas file fmt grep gzip -SUBDIR+= m4 mandoc openssl sdiff sed signify sort tsort +SUBDIR+= m4 mandoc openssl rev sdiff sed signify sort tsort SUBDIR+= xargs .if defined(REGRESS_FULL) || make(clean) || make(cleandir) || make(obj) diff --git a/regress/usr.bin/rev/Makefile b/regress/usr.bin/rev/Makefile new file mode 100644 index 00000000000..1780774eb2f --- /dev/null +++ b/regress/usr.bin/rev/Makefile @@ -0,0 +1,11 @@ +# $OpenBSD: Makefile,v 1.1 2016/04/10 15:00:03 schwarze Exp $ + +CLEANFILES = out.ascii.txt out.utf8.txt + +regress: + LC_ALL=C rev ${.CURDIR}/in.txt > out.ascii.txt + diff -u ${.CURDIR}/exp.ascii.txt out.ascii.txt + LC_ALL=en_US.UTF-8 rev ${.CURDIR}/in.txt > out.utf8.txt + diff -u ${.CURDIR}/exp.utf8.txt out.utf8.txt + +.include <bsd.regress.mk> diff --git a/regress/usr.bin/rev/exp.ascii.txt b/regress/usr.bin/rev/exp.ascii.txt new file mode 100644 index 00000000000..8213bd1ec93 --- /dev/null +++ b/regress/usr.bin/rev/exp.ascii.txt @@ -0,0 +1,8 @@ +iicsa + +…ˆâ +laitinà +‚Åanif +el‘Ïim +‚ϿγΌϻΠ+‰ƒã¼ƒã¯ƒã diff --git a/regress/usr.bin/rev/exp.utf8.txt b/regress/usr.bin/rev/exp.utf8.txt new file mode 100644 index 00000000000..01895432eaa --- /dev/null +++ b/regress/usr.bin/rev/exp.utf8.txt @@ -0,0 +1,8 @@ +iicsa + +∅ +laitinà +Å‚anif +elÏ‘im +ςογόλ +ドーワ diff --git a/regress/usr.bin/rev/in.txt b/regress/usr.bin/rev/in.txt new file mode 100644 index 00000000000..9f9eb5fd02f --- /dev/null +++ b/regress/usr.bin/rev/in.txt @@ -0,0 +1,8 @@ +ascii + +∅ +Ãnitial +finaÅ‚ +miÏ‘le +λόγος +ワード |