From 6ca0d65df1e595df32db021669b8ba11b013a3a4 Mon Sep 17 00:00:00 2001 From: nicm Date: Wed, 28 Jun 2017 17:28:39 +0000 Subject: [PATCH] Test for file from stdin. --- regress/usr.bin/file/Makefile | 10 ++++++++-- regress/usr.bin/file/stdin.out | 1 + 2 files changed, 9 insertions(+), 2 deletions(-) create mode 100644 regress/usr.bin/file/stdin.out diff --git a/regress/usr.bin/file/Makefile b/regress/usr.bin/file/Makefile index d08124c3789..dad20ca1d83 100644 --- a/regress/usr.bin/file/Makefile +++ b/regress/usr.bin/file/Makefile @@ -1,10 +1,10 @@ -# $OpenBSD: Makefile,v 1.7 2016/05/01 11:28:06 nicm Exp $ +# $OpenBSD: Makefile,v 1.8 2017/06/28 17:28:39 nicm Exp $ FILE=file REGRESS_TARGETS=t0 t1 t2 t3 t4 t5 t6 t7 \ t8 t9 t10 t11 t15 t17 t18 t19 \ - t20 t21 t22 t30 t31 t32 t33 + t20 t21 t22 t30 t31 t32 t33 stdin # .in: input file # .out: desired result @@ -20,6 +20,12 @@ all: ${REGRESS_TARGET} diff - ${.CURDIR}/${*}.out || \ (echo "XXX ${*} failed" && false) +stdin: + @echo ${*} + @${FILE} - diff --git a/regress/usr.bin/file/stdin.out b/regress/usr.bin/file/stdin.out new file mode 100644 index 00000000000..be8e3228df9 --- /dev/null +++ b/regress/usr.bin/file/stdin.out @@ -0,0 +1 @@ +/dev/stdin: empty -- 2.20.1