diff --git a/tests/ahci_test.in b/tests/ahci_test.in index 56760326a..7853bb8b6 100644 --- a/tests/ahci_test.in +++ b/tests/ahci_test.in @@ -44,8 +44,8 @@ tar cf "$imgfile" "$outfile" v=$(echo "nativedisk; source '(ahci0)/$outfile';" | "${grubshell}" --qemu-opts="-drive id=disk,file=$imgfile,if=none -device ahci,id=ahci - -device ide-hd,drive=disk,bus=ahci.0" | - tail -n 1) + -device ide-hd,drive=disk,bus=ahci.0") +v=$(echo "$v" | tail -n 1) if [ "$v" != "Hello World" ]; then rm "$imgfile" rm "$outfile" diff --git a/tests/ehci_test.in b/tests/ehci_test.in index c368c59ec..426bfa7db 100644 --- a/tests/ehci_test.in +++ b/tests/ehci_test.in @@ -44,8 +44,8 @@ tar cf "$imgfile" "$outfile" v=$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device ich9-usb-ehci1 -drive id=my_usb_disk,file=$imgfile,if=none - -device usb-storage,drive=my_usb_disk" | - tail -n 1) + -device usb-storage,drive=my_usb_disk") +v=$(echo "$v" | tail -n 1) if [ "$v" != "Hello World" ]; then rm "$imgfile" rm "$outfile" diff --git a/tests/grub_cmd_date.in b/tests/grub_cmd_date.in index f7c9ca004..737a278e6 100644 --- a/tests/grub_cmd_date.in +++ b/tests/grub_cmd_date.in @@ -9,7 +9,8 @@ if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; fi pdt="$(date -u +%s)" -dt=`echo date | @builddir@/grub-shell | sed 's, [A-Z][a-z]*$,,'` +dt="$(echo date | @builddir@/grub-shell)" +dt="$(echo "$dt" | sed 's, [A-Z][a-z]*$,,')" dtg="$(date -u -d "$dt" +%s)" ndt="$(date -u +%s)" diff --git a/tests/grub_script_expansion.in b/tests/grub_script_expansion.in index 9d0dcdd29..98d5a9068 100644 --- a/tests/grub_script_expansion.in +++ b/tests/grub_script_expansion.in @@ -17,7 +17,8 @@ set -e # You should have received a copy of the GNU General Public License # along with GRUB. If not, see . -disks=`echo ls | @builddir@/grub-shell| grep -av '^Network protocols:$'| grep -av '^tftp http $'` +disks=`echo ls | @builddir@/grub-shell` +disks=`echo "$disks"| grep -av '^Network protocols:$'| grep -av '^tftp http $'` other=`echo insmod regexp\; echo \* | @builddir@/grub-shell` for d in $disks; do if echo "$d" |grep ',' >/dev/null; then diff --git a/tests/ohci_test.in b/tests/ohci_test.in index 45949fb4c..2b96539b8 100644 --- a/tests/ohci_test.in +++ b/tests/ohci_test.in @@ -44,8 +44,8 @@ tar cf "$imgfile" "$outfile" v=$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device pci-ohci -drive id=my_usb_disk,file=$imgfile,if=none - -device usb-storage,drive=my_usb_disk" | - tail -n 1) + -device usb-storage,drive=my_usb_disk") +v=$(echo "$v" | tail -n 1) if [ "$v" != "Hello World" ]; then rm "$imgfile" rm "$outfile" diff --git a/tests/partmap_test.in b/tests/partmap_test.in index 7353dc70e..5f18ab51c 100644 --- a/tests/partmap_test.in +++ b/tests/partmap_test.in @@ -58,8 +58,8 @@ list_parts () { shift echo ls | "${grubshell}" --disk="${imgfile}" \ - --modules=$mod | tr -d "\n\r" > "${outfile}" - cat "${outfile}" + --modules=$mod > "${outfile}" + cat "${outfile}" | tr -d "\n\r" echo } diff --git a/tests/uhci_test.in b/tests/uhci_test.in index 5a3b94c65..9a9492a43 100644 --- a/tests/uhci_test.in +++ b/tests/uhci_test.in @@ -44,8 +44,8 @@ tar cf "$imgfile" "$outfile" v=$(echo "nativedisk; source '(usb0)/$outfile';" | "${grubshell}" --qemu-opts="-device ich9-usb-uhci1 -drive id=my_usb_disk,file=$imgfile,if=none - -device usb-storage,drive=my_usb_disk" | - tail -n 1) + -device usb-storage,drive=my_usb_disk") +v=$(echo "$v" | tail -n 1) if [ "$v" != "Hello World" ]; then rm "$imgfile" rm "$outfile"