Revert "ci: skip "lib/test-fork-safe-execvpe.sh" on Alpine Linux"
[libnbd.git] / copy / test-short-options.sh
blob6d51cd7f807c4280cd663c0a6d87258494170d0f
1 #!/usr/bin/env bash
2 # nbd client library in userspace
3 # Copyright Red Hat
5 # This library is free software; you can redistribute it and/or
6 # modify it under the terms of the GNU Lesser General Public
7 # License as published by the Free Software Foundation; either
8 # version 2 of the License, or (at your option) any later version.
10 # This library is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 # Lesser General Public License for more details.
15 # You should have received a copy of the GNU Lesser General Public
16 # License along with this library; if not, write to the Free Software
17 # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
19 # Test that nbdcopy --short-options looks sane.
21 . ../tests/functions.sh
22 set -e
23 set -x
25 output=test-short-options.out
26 cleanup_fn rm -f $output
28 $VG nbdcopy --short-options > $output
29 if [ $? != 0 ]; then
30 echo "$0: unexpected exit status"
31 fail=1
33 cat $output
34 grep -- -C $output
35 grep -- -R $output
36 grep -- -V $output