Debian Codegraph @

tests/inst-3

raw
1 #! /bin/sh
2 # Test the new --y2k options
3 dd if=test-old of=test-mbr 2>/dev/null
4 do_install -y -d 0xb3 -t 132 -p 3 -i n -e 14 test-mbr
5 do_install -l test-mbr >test-y
6 cat <<EOF >test-x
7 Version: 2
8 Compatible: 2
9 Y2K-Fix: Enabled
10 Drive: 0xb3
11 Default: 3
12 Timeout: 132/18 seconds
13 Enabled: 1 4
14 Interrupt:
15 EOF
16 diff -u test-x test-y
17
18 do_cmp y2k.b test-mbr bs=432 count=1
19 do_cmp /dev/zero test-mbr bs=2 skip=223 count=32
20 do_cmp y2k.b test-mbr bs=2 skip=223
21
22 # Try different options.
23 dd if=test-old of=test-mbr 2>/dev/null
24 dd if=test-old of=test-mbr-u 2>/dev/null
25 dd if=test-old of=test-mbr-l 2>/dev/null
26 do_install -yu test-mbr-u
27 do_install -yr test-mbr 2>/dev/null && exit 1
28 do_install -yutc test-mbr
29 cmp test-mbr test-mbr-u
30 do_install -yum test-mbr 2>/dev/null && exit 1
31 do_install -yl test-mbr-l
32 do_install -yloval test-mbr 2>/dev/null && exit 1
33 do_install -ylocal test-mbr
34 cmp test-mbr test-mbr-l
35 do_install -y test-mbr
36 cmp test-mbr test-mbr-u || cmp test-mbr test-mbr-l
37
38 : Done