From a4215743db91c4b7050dfda32a670814a101b773 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Sun, 27 Jan 2013 21:10:30 +0100 Subject: Defining 'APP_HOME' as where the .app dir is. The tools should use this value to find files. app-operate/app-operator-pid: These are "functional" now. --- test/app-init.bats | 4 +++- test/data/app-a/hooks/post-install | 4 ++++ test/data/app-a/root/bin/app-a | 3 ++- 3 files changed, 9 insertions(+), 2 deletions(-) mode change 100644 => 100755 test/data/app-a/root/bin/app-a (limited to 'test') diff --git a/test/app-init.bats b/test/app-init.bats index 10edc63..df3919e 100755 --- a/test/app-init.bats +++ b/test/app-init.bats @@ -38,7 +38,9 @@ load utils eq '${lines[3]}' "Unpacking..." match '${lines[4]}' "Creating current symlink for version 1.0-.*" eq '${lines[5]}' "Post install" - eq '${#lines[*]}' 6 + eq '${#lines[*]}' 6 is_directory "my-app/.app" + # Created by post-install + is_directory "my-app/logs" } diff --git a/test/data/app-a/hooks/post-install b/test/data/app-a/hooks/post-install index 99ad974..c548ad7 100755 --- a/test/data/app-a/hooks/post-install +++ b/test/data/app-a/hooks/post-install @@ -3,3 +3,7 @@ set -u echo "Post install" + +[ -d ../../logs ] || mkdir ../../logs + +ln -s ../../../logs root/logs diff --git a/test/data/app-a/root/bin/app-a b/test/data/app-a/root/bin/app-a old mode 100644 new mode 100755 index 98d98cd..d332993 --- a/test/data/app-a/root/bin/app-a +++ b/test/data/app-a/root/bin/app-a @@ -1,8 +1,9 @@ #!/bin/bash -#cd $APPSH_INSTANCE_HOME me=`basename $0` +trap 'echo Signalled >> logs/$me.log; exit 0' TERM INT QUIT + env | grep TEST_PROPERTY >> logs/$me.env echo "Starting" >> logs/$me.log -- cgit v1.2.3