Debian Codegraph @

testsuite/lid-range

raw symbols SCIP
1 #!/bin/sh
2 # Demonstrate how lid's open-ended ranges work
3
4 # Copyright (C) 2011-2020 Free Software Foundation, Inc.
5
6 # This program is free software: you can redistribute it and/or modify
7 # it under the terms of the GNU General Public License as published by
8 # the Free Software Foundation, either version 3 of the License, or
9 # (at your option) any later version.
10
11 # This program is distributed in the hope that it will be useful,
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 # GNU General Public License for more details.
15
16 # You should have received a copy of the GNU General Public License
17 # along with this program. If not, see <http://www.gnu.org/licenses/>.
18
19 . "${srcdir=.}/init.sh"; path_prepend_ ../src
20
21 cat <<\EOF > in.txt || framework_failure_
22 one
23 two two
24 three three three
25 four four four four
26 EOF
27
28 echo '*.txt text' > map || framework_failure_
29
30 mkid -m map || framework_failure_
31
32 cat <<\EOF > exp || framework_failure_
33 one in.txt
34 two in.txt
35 EOF
36 lid -F ..2 > out || fail=1
37 compare exp out || fail=1
38
39 cat <<\EOF > exp || framework_failure_
40 four in.txt
41 three in.txt
42 two in.txt
43 EOF
44 lid -F 2.. > out || fail=1
45 compare exp out || fail=1
46
47 Exit $fail