Message ID | 1418864165-32419-1-git-send-email-joel@jms.id.au |
---|---|
State | Accepted |
Headers | show |
diff --git a/test/hello_world/run_hello_world.sh b/test/hello_world/run_hello_world.sh index dcb79a8..f72c402 100755 --- a/test/hello_world/run_hello_world.sh +++ b/test/hello_world/run_hello_world.sh @@ -14,7 +14,12 @@ if [ ! -x "$MAMBO_PATH/$MAMBO_BINARY" ]; then exit 0; fi -if [ ! -x `which expect` ]; then +if [ -n "$KERNEL" ]; then + echo 'Please rebuild skiboot without KERNEL set. Skipping hello_world test'; + exit 0; +fi + +if [ ! `command -v expect` ]; then echo 'Could not find expect binary. Skipping hello_world test'; exit 0; fi
The test for expect would always return true. This change makes it do the correct thing in the presence and absence of expect on my Ubuntu machine. Also, skip the test if the user has KERNEL set. With this set skiboot contains an embedded kernel, and will load that before falling back to our hello_world test kernel, causing all kinds of confusion. Signed-off-by: Joel Stanley <joel@jms.id.au> --- test/hello_world/run_hello_world.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)