File: lvlsave.test

package info (click to toggle)
heroes 0.21-10
  • links: PTS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 4,744 kB
  • ctags: 3,167
  • sloc: ansic: 27,966; sh: 4,188; makefile: 696; yacc: 318; sed: 51; lisp: 10; perl: 9
file content (18 lines) | stat: -rwxr-xr-x 458 bytes parent folder | download | duplicates (11)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh
# Test to make sure that loaded level are saved identically.

. $srcdir/defs || exit 1

set -e

for lvl in `$HEROES --list=levels | awk '{ print $2 }'`; do
  ./lvlsave $lvl testout
  # Don't make a binary comparison, because it's ok to have some
  # difference like case in filename, etc.
  $HEROESLVL -phidtw@ $lvl > testin.out
  $HEROESLVL -phidtw@ testout > testout.out
  diff testin.out testout.out
done

rm -f testout testin.out testout.out
: