mirror of
https://git.savannah.gnu.org/git/grub.git
synced 2026-10-21 14:59:34 +00:00
tests: Exit with skipped exit code when test not performed
These tests were not performed and therefore did not pass, nor fail. This fixes misleading test exit code where, for instance, the pseries_test will pass on i386-pc, which is not a pseries architecture. Signed-off-by: Glenn Washburn <development@efficientek.com> Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
This commit is contained in:
1 parent
bcb15e011a
commit
4dc5259b6e
15 files changed
+51
-51
No files matched your search
+4
-4
@@ -22,16 +22,16 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: Don't mess with real devices when OS is active
|
# PLATFORM: Don't mess with real devices when OS is active
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: qemu gets bonito DMA wrong
|
# FIXME: qemu gets bonito DMA wrong
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: no AHCI on ARC and qemu-mips platforms
|
# PLATFORM: no AHCI on ARC and qemu-mips platforms
|
||||||
mips*-arc | mips*-qemu_mips)
|
mips*-arc | mips*-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: No native drivers are available for those
|
# FIXME: No native drivers are available for those
|
||||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
||||||
|
|||||||
@@ -22,16 +22,16 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: emu is different
|
# PLATFORM: emu is different
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: Flash targets
|
# PLATFORM: Flash targets
|
||||||
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: currently grub-shell uses only -kernel for loongson
|
# FIXME: currently grub-shell uses only -kernel for loongson
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: OFW fails to open CD-ROM
|
# FIXME: OFW fails to open CD-ROM
|
||||||
i386-ieee1275)
|
i386-ieee1275)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
v=$(echo hello | "${grubshell}" --boot=cd)
|
v=$(echo hello | "${grubshell}" --boot=cd)
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# FIXME: Only mips currently supports configurable core compression
|
# FIXME: Only mips currently supports configurable core compression
|
||||||
*-emu | i386-* | x86_64-* | sparc64-* | ia64-*)
|
*-emu | i386-* | x86_64-* | sparc64-* | ia64-*)
|
||||||
exit 0
|
exit 77
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|||||||
+4
-4
@@ -22,16 +22,16 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: Don't mess with real devices when OS is active
|
# PLATFORM: Don't mess with real devices when OS is active
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: qemu gets bonito DMA wrong
|
# FIXME: qemu gets bonito DMA wrong
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: no USB on ARC and qemu-mips platforms
|
# PLATFORM: no USB on ARC and qemu-mips platforms
|
||||||
mips*-arc | mips*-qemu_mips)
|
mips*-arc | mips*-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: No native drivers are available for those
|
# FIXME: No native drivers are available for those
|
||||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
||||||
|
|||||||
@@ -22,28 +22,28 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: emu is different
|
# PLATFORM: emu is different
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: Flash targets
|
# PLATFORM: Flash targets
|
||||||
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: currently grub-shell uses only -kernel for loongson
|
# FIXME: currently grub-shell uses only -kernel for loongson
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: We don't support EFI floppy boot in grub-mkrescue
|
# FIXME: We don't support EFI floppy boot in grub-mkrescue
|
||||||
*-efi)
|
*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: no floppy support
|
# FIXME: no floppy support
|
||||||
i386-multiboot)
|
i386-multiboot)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: QEMU firmware crashes when trying to boot from floppy
|
# FIXME: QEMU firmware crashes when trying to boot from floppy
|
||||||
sparc64-ieee1275)
|
sparc64-ieee1275)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: QEMU doesn't emulate SCSI floppies
|
# FIXME: QEMU doesn't emulate SCSI floppies
|
||||||
mipsel-arc | mips-arc)
|
mipsel-arc | mips-arc)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: powerpc doesn't boot from floppy except OldWorld Macs which we don't support anyway
|
# PLATFORM: powerpc doesn't boot from floppy except OldWorld Macs which we don't support anyway
|
||||||
powerpc-ieee1275)
|
powerpc-ieee1275)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
v=$(echo hello | "${grubshell}" --boot=fd --mkrescue-arg="--compress=xz --fonts= --locales= --themes= -no-pad")
|
v=$(echo hello | "${grubshell}" --boot=fd --mkrescue-arg="--compress=xz --fonts= --locales= --themes= -no-pad")
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ set -e
|
|||||||
|
|
||||||
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
||||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then
|
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then
|
||||||
exit 0
|
exit 77
|
||||||
fi
|
fi
|
||||||
|
|
||||||
pdt="$(date -u +%s)"
|
pdt="$(date -u +%s)"
|
||||||
|
|||||||
@@ -6,15 +6,15 @@ set -e
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
||||||
sparc64-ieee1275)
|
sparc64-ieee1275)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: ARC doesn't provide any way to set time
|
# PLATFORM: ARC doesn't provide any way to set time
|
||||||
*-arc)
|
*-arc)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: EMU doesn't provide any way to set time
|
# PLATFORM: EMU doesn't provide any way to set time
|
||||||
# Even if it did we'd need some kind of sandbox to avoid
|
# Even if it did we'd need some kind of sandbox to avoid
|
||||||
# modifying real system time.
|
# modifying real system time.
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
out=$(cat <<EOF | @builddir@/grub-shell
|
out=$(cat <<EOF | @builddir@/grub-shell
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ set -e
|
|||||||
|
|
||||||
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
# FIXME: OpenBIOS on sparc64 doesn't implement RTC
|
||||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then
|
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" = sparc64-ieee1275 ]; then
|
||||||
exit 0
|
exit 77
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Compare RTC with interval timer.
|
# Compare RTC with interval timer.
|
||||||
|
|||||||
@@ -22,13 +22,13 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: emu is different
|
# PLATFORM: emu is different
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: Flash targets
|
# PLATFORM: Flash targets
|
||||||
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: currently grub-shell uses only -kernel for loongson
|
# FIXME: currently grub-shell uses only -kernel for loongson
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
v=$(echo hello | "${grubshell}" --boot=hd)
|
v=$(echo hello | "${grubshell}" --boot=hd)
|
||||||
|
|||||||
@@ -22,22 +22,22 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: emu is different
|
# PLATFORM: emu is different
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: Flash targets
|
# PLATFORM: Flash targets
|
||||||
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
i386-qemu | i386-coreboot | mips-qemu_mips | mipsel-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: currently grub-shell uses only -kernel for loongson
|
# FIXME: currently grub-shell uses only -kernel for loongson
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: no rtl8139 support
|
# FIXME: no rtl8139 support
|
||||||
i386-multiboot)
|
i386-multiboot)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: We don't fully support netboot on ARC
|
# FIXME: We don't fully support netboot on ARC
|
||||||
*-arc)
|
*-arc)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: Many QEMU firmware have no netboot capability
|
# FIXME: Many QEMU firmware have no netboot capability
|
||||||
*-efi | i386-ieee1275 | powerpc-ieee1275 | sparc64-ieee1275)
|
*-efi | i386-ieee1275 | powerpc-ieee1275 | sparc64-ieee1275)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
v=$(echo hello | "${grubshell}" --boot=net)
|
v=$(echo hello | "${grubshell}" --boot=net)
|
||||||
|
|||||||
+4
-4
@@ -22,16 +22,16 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: Don't mess with real devices when OS is active
|
# PLATFORM: Don't mess with real devices when OS is active
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: qemu gets bonito DMA wrong
|
# FIXME: qemu gets bonito DMA wrong
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: no USB on ARC and qemu-mips platforms
|
# PLATFORM: no USB on ARC and qemu-mips platforms
|
||||||
mips*-arc | mips*-qemu_mips)
|
mips*-arc | mips*-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: No native drivers are available for those
|
# FIXME: No native drivers are available for those
|
||||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
||||||
|
|||||||
@@ -70,21 +70,21 @@ case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
|||||||
powerpc-ieee1275)
|
powerpc-ieee1275)
|
||||||
disk=ieee1275//pci@80000000/mac-io@4/ata-3@20000/disk@0
|
disk=ieee1275//pci@80000000/mac-io@4/ata-3@20000/disk@0
|
||||||
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
||||||
exit 0
|
exit 77
|
||||||
;;
|
;;
|
||||||
sparc64-ieee1275)
|
sparc64-ieee1275)
|
||||||
disk=ieee1275//pci@1fe\,0/pci-ata@5/ide0@500/disk@0
|
disk=ieee1275//pci@1fe\,0/pci-ata@5/ide0@500/disk@0
|
||||||
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
||||||
exit 0
|
exit 77
|
||||||
;;
|
;;
|
||||||
i386-ieee1275)
|
i386-ieee1275)
|
||||||
disk=ieee1275/d
|
disk=ieee1275/d
|
||||||
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
# FIXME: QEMU firmware has bugs which prevent it from accessing hard disk w/o recognised label.
|
||||||
exit 0
|
exit 77
|
||||||
;;
|
;;
|
||||||
mips-arc)
|
mips-arc)
|
||||||
# FIXME: ARC firmware has bugs which prevent it from accessing hard disk w/o dvh disklabel.
|
# FIXME: ARC firmware has bugs which prevent it from accessing hard disk w/o dvh disklabel.
|
||||||
exit 0 ;;
|
exit 77 ;;
|
||||||
mipsel-arc)
|
mipsel-arc)
|
||||||
disk=arc/scsi0/disk0/rdisk0
|
disk=arc/scsi0/disk0/rdisk0
|
||||||
;;
|
;;
|
||||||
|
|||||||
+3
-3
@@ -25,13 +25,13 @@ indisk=ata0
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: Don't mess with real devices when OS is active
|
# PLATFORM: Don't mess with real devices when OS is active
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: no ATA on ARC platforms (they use SCSI)
|
# PLATFORM: no ATA on ARC platforms (they use SCSI)
|
||||||
*-arc)
|
*-arc)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: No native drivers are available for those
|
# FIXME: No native drivers are available for those
|
||||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
i386-ieee1275)
|
i386-ieee1275)
|
||||||
disk=hdb
|
disk=hdb
|
||||||
indisk=ata1
|
indisk=ata1
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ grubshell=@builddir@/grub-shell
|
|||||||
. "@builddir@/grub-core/modinfo.sh"
|
. "@builddir@/grub-core/modinfo.sh"
|
||||||
|
|
||||||
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" != powerpc-ieee1275 ]; then
|
if [ "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" != powerpc-ieee1275 ]; then
|
||||||
exit 0
|
exit 77
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$(echo hello | "${grubshell}" --pseries --timeout=180 --boot=cd)" != "Hello World" ]; then
|
if [ "$(echo hello | "${grubshell}" --pseries --timeout=180 --boot=cd)" != "Hello World" ]; then
|
||||||
|
|||||||
+4
-4
@@ -22,16 +22,16 @@ grubshell=@builddir@/grub-shell
|
|||||||
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
case "${grub_modinfo_target_cpu}-${grub_modinfo_platform}" in
|
||||||
# PLATFORM: Don't mess with real devices when OS is active
|
# PLATFORM: Don't mess with real devices when OS is active
|
||||||
*-emu)
|
*-emu)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: qemu gets bonito DMA wrong
|
# FIXME: qemu gets bonito DMA wrong
|
||||||
mipsel-loongson)
|
mipsel-loongson)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# PLATFORM: no USB on ARC and qemu-mips platforms
|
# PLATFORM: no USB on ARC and qemu-mips platforms
|
||||||
mips*-arc | mips*-qemu_mips)
|
mips*-arc | mips*-qemu_mips)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
# FIXME: No native drivers are available for those
|
# FIXME: No native drivers are available for those
|
||||||
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
powerpc-ieee1275 | sparc64-ieee1275 | arm*-efi)
|
||||||
exit 0;;
|
exit 77;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
imgfile="`mktemp "${TMPDIR:-/tmp}/tmp.XXXXXXXXXX"`" || exit 99
|
||||||
|
|||||||
Reference in new issue
Block a user