about summary refs log tree commit diff
path: root/test/pamvalidate.test
blob: 708197da22e383270b3d5c71d39752d335c55c17 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /bin/sh
# This script tests: pamvalidate
# Also requires:

echo "valid"
printf "P1\n5 5\n01010\n10101\n01010\n00000\n11111\n" | pamvalidate -plain

echo "not valid: Should print 0 four times"
printf "P1\n5 5\n01010\n10101\n01010\n00000\n1111\n"  | pamvalidate | \
  wc -c | tr -d ' '

printf "P1\n5 5\n01010\n10102\n01010\n00001\n11111\n" | pamvalidate | \
  wc -c | tr -d ' '

printf "P1\n5\n01010\n10101\n01010\n00000\n11111\n" | pamvalidate | \
  wc -c | tr -d ' '

printf "P1\n5 5" | pamvalidate | wc -c | tr -d ' '