1#!/bin/sh 2# SPDX-License-Identifier: GPL-2.0-or-later 3# Copyright (c) 2020 Petr Vorel <pvorel@suse.cz> 4 5TST_TESTFUNC=do_test 6PATH="$(dirname $0)/../../../../testcases/lib/:$PATH" 7 8export TST_NET_RHOST_RUN_DEBUG=1 9 10do_test() 11{ 12 local file="/etc/fstab" 13 14 tst_rhost_run -c 'which grep' > /dev/null || \ 15 tst_brk TCONF "grep not found on rhost" 16 17 tst_rhost_run -c "[ -f $file ]" || \ 18 tst_brk TCONF "$file not found on rhost" 19 20 tst_rhost_run -s -c "grep -q \"[^ ]\" $file" 21 tst_rhost_run -s -c "grep -q '[^ ]' $file" 22 23 tst_res TPASS "tst_rhost_run is working" 24} 25 26. tst_net.sh 27tst_run 28