File: inout-3.tst

package info (click to toggle)
a2ps 1%3A4.14-4
  • links: PTS
  • area: main
  • in suites: buster
  • size: 13,328 kB
  • sloc: ansic: 26,966; sh: 11,844; lex: 2,286; perl: 1,156; yacc: 757; makefile: 609; lisp: 398; ada: 263; objc: 189; f90: 109; ml: 85; sql: 74; pascal: 57; modula3: 33; haskell: 32; sed: 30; java: 29; python: 24
file content (27 lines) | stat: -rwxr-xr-x 544 bytes parent folder | download | duplicates (15)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#! /bin/sh
# -*- ksh -*-

# This program checks that a2ps correctly reads stdin, and
# writes on stdout.  In particular, we check both with -Eplain
# specified, and without (i.e., -E alone).

: ${SRCDIR=.}

# failure?
fail=0

# The options to run with
OPT="-o- -"

# The testing file
IN_NAME=report.pre

# Set up other vars
. $SRCDIR/defs || exit 1

# 3. Read stdin, produce on stdout, set automatic ssh selection on
nlines=`cat $TST_FILE | $CHK $OPT -E | wc -l | sed 's/[ \t]//g'`
test $? = 0 || fail=1
test $nlines != 0 || fail=1

exit $fail