aboutsummaryrefslogtreecommitdiff
path: root/test/it-install-remove.bats
diff options
context:
space:
mode:
authorTrygve Laugstøl <trygvis@inamo.no>2012-10-17 10:55:23 +0200
committerTrygve Laugstøl <trygvis@inamo.no>2012-10-17 10:55:23 +0200
commitc5401a6d595a595ee16ee6aede55fb016b9cfdfd (patch)
tree93d9bb33837bc1cea44ba4ca3c8ce9f8882ab523 /test/it-install-remove.bats
parenta3ce3f7eabbb746aa9ced430bcd55391742c738b (diff)
downloadapp.sh-c5401a6d595a595ee16ee6aede55fb016b9cfdfd.tar.gz
app.sh-c5401a6d595a595ee16ee6aede55fb016b9cfdfd.tar.bz2
app.sh-c5401a6d595a595ee16ee6aede55fb016b9cfdfd.tar.xz
app.sh-c5401a6d595a595ee16ee6aede55fb016b9cfdfd.zip
o Proper implementation of start, stop and status.
Diffstat (limited to 'test/it-install-remove.bats')
-rwxr-xr-xtest/it-install-remove.bats24
1 files changed, 17 insertions, 7 deletions
diff --git a/test/it-install-remove.bats b/test/it-install-remove.bats
index 98a79c9..3358118 100755
--- a/test/it-install-remove.bats
+++ b/test/it-install-remove.bats
@@ -5,18 +5,28 @@ load utils
@test "install remove roundtrip" {
mkzip "app-a"
- a="-n app-a -i prod"
+ name="app-a"
+ instance="prod"
+ a="-n $name -i $instance"
+
+ describe "Installing $name/$instance"
app instance install \
-r file \
-u $BATS_TEST_DIRNAME/data/app-a.zip \
- $a
+ -n $name -i $instance
+
+# set -x
+ can_not_read ".app/var/pid/$name-$instance.pid"
- [ ! -r .app/var/pid/$name-$instance.pid ]
- app $a operate start; echo_lines
- [ -r .app/var/pid/$name-$instance.pid ]
+ describe "Starting $name/$instance"
+ app -n $name -i $instance operate start
+ echo_lines
+ can_read .app/var/pid/$name-$instance.pid
- app $a operate stop; echo_lines
- [ ! -r .app/var/pid/$name-$instance.pid ]
+ describe "Stopping $name/$instance"
+ app -n $name -i $instance operate stop
+ echo_lines
+ can_not_read .app/var/pid/$name-$instance.pid
# app instance install \
# -r file \