Debian Codegraph @

tests/newline6/run-test

raw
1 #!/bin/sh
2 #
3 # This is a filterdiff(1) test case.
4 # Test: Handle adding newline to EOF
5
6 . ${top_srcdir-.}/tests/common.sh
7
8 cat << EOF > orig
9 a
10 b
11 EOF
12 echo -n c >> orig
13 cat << EOF > new
14 a
15 b
16 c
17 EOF
18
19 ${DIFF} -c orig new > patch
20 ${FILTERDIFF} patch 2>errors > filtered || exit 1
21 [ -s errors ] && exit 1
22
23 ${PATCH} orig -i filtered || exit 1
24 cmp orig new || exit 1