Import basic test for Multiboot conformance
This commit is contained in:
parent
c289b6e529
commit
8150cd7366
|
@ -1,5 +1,5 @@
|
|||
package=uKernel
|
||||
version=0.0.0
|
||||
|
||||
subdirs=src
|
||||
subdirs=src,tests
|
||||
dist=Makefile
|
||||
|
|
43
tests/grub.sh
Executable file
43
tests/grub.sh
Executable file
|
@ -0,0 +1,43 @@
|
|||
#!/bin/sh
|
||||
|
||||
|
||||
#variables
|
||||
PROGNAME="grub.sh"
|
||||
#executables
|
||||
GRUBFILE="grub-file"
|
||||
UNAME="uname"
|
||||
|
||||
|
||||
#functions
|
||||
#error
|
||||
_error()
|
||||
{
|
||||
echo "$PROGNAME: $@" 1>&2
|
||||
return 2
|
||||
}
|
||||
|
||||
|
||||
#info
|
||||
_info()
|
||||
{
|
||||
echo "$PROGNAME: $@"
|
||||
}
|
||||
|
||||
|
||||
#main
|
||||
case $($UNAME -m) in
|
||||
amd64|i?86)
|
||||
_info "Testing multiboot conformance"
|
||||
$GRUBFILE --is-x86-multiboot ../uKernel.bin
|
||||
res=$?
|
||||
if [ $res -eq 127 ]; then
|
||||
_error "Cannot test: $GRUBFILE not available (ignored)"
|
||||
exit 0
|
||||
elif [ $req -ne 0 ]; then
|
||||
_error ""
|
||||
exit $?
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
1
tests/project.conf
Normal file
1
tests/project.conf
Normal file
|
@ -0,0 +1 @@
|
|||
dist=Makefile,grub.sh
|
Loading…
Reference in New Issue
Block a user