| #!/bin/sh |
| |
|
|
| |
|
|
| |
| |
| |
| |
|
|
| |
| |
| |
| |
|
|
| |
| |
|
|
| . "${srcdir=.}/tests/init.sh"; path_prepend_ ./src |
| print_ver_ ginstall |
| require_root_ |
| skip_if_setgid_ |
| skip_if_nondefault_group_ |
|
|
| u1=1 |
| u2=2 |
| g1=1 |
| g2=2 |
|
|
|
|
| echo test > a || framework_failure_ |
| echo "'a' -> 'b'" > out_installed_first |
| echo "removed 'b' |
| 'a' -> 'b'" > out_installed_second |
| > out_empty |
|
|
| |
| ginstall -Cv -o$u1 -g$g1 a b > out || fail=1 |
| compare out out_installed_first || fail=1 |
|
|
| |
| ginstall -Cv -o$u1 -g$g1 a b > out || fail=1 |
| compare out out_empty || fail=1 |
|
|
| |
| ginstall -v -o$u1 -g$g1 a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
|
|
| |
| ginstall -Cv -o$u2 -g$g1 a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv -o$u2 -g$g1 a b > out || fail=1 |
| compare out out_empty || fail=1 |
|
|
| |
| ginstall -Cv -o$u2 -g$g2 a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv -o$u2 -g$g2 a b > out || fail=1 |
| compare out out_empty || fail=1 |
|
|
| |
| ginstall -Cv -o$u2 a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv a b > out || fail=1 |
| compare out out_empty || fail=1 |
|
|
| |
| ginstall -Cv -g$g2 a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv a b > out || fail=1 |
| compare out out_installed_second || fail=1 |
| ginstall -Cv a b > out || fail=1 |
| compare out out_empty || fail=1 |
|
|
| Exit $fail |
|
|