ttest.sh - neatvi - [fork] simple vi-type editor with UTF-8 support
(HTM) git clone git://src.adamsgaard.dk/neatvi
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
---
ttest.sh (368B)
---
1 #!/bin/sh
2
3 # testcase vi_options test.sh
4 testcase() {
5 rm -f /tmp/.neatvi[12]
6 printf "$x: "
7 sh $2 /tmp/.neatvi2 2>/tmp/.neatvi1 | ./vi $1 >/dev/null
8 if ! cmp -s /tmp/.neatvi[12]; then
9 printf "Failed\n"
10 diff -u /tmp/.neatvi[12]
11 exit 1
12 fi
13 printf "OK\n"
14 }
15
16 for x in test/e??.sh; do
17 testcase "-s -e" "$x"
18 done
19 for x in test/v??.sh; do
20 testcase "-v" "$x"
21 done