Skip to content

Commit

Permalink
Adds kitchen tests for the restapi
Browse files Browse the repository at this point in the history
  • Loading branch information
Walter Huf committed Oct 14, 2014
1 parent e4a4973 commit 3337ba4
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions recipes/all_in_one.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,4 @@
include_recipe 'ceph::mds'
include_recipe 'ceph::cephfs'
include_recipe 'ceph::radosgw'
include_recipe 'ceph::restapi'
16 changes: 16 additions & 0 deletions test/integration/aio/bats/restapi.bats
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
@test "restapi client key is generated" {
test -e /etc/ceph/ceph.client.restapi*
}

@test "restapi is configured" {
test -e /etc/apache2/sites-enabled/restapi.conf
grep -F 'WSGIScriptAlias / /usr/lib/ceph/restapi.wsgi' /etc/apache2/sites-enabled/restapi.conf > /dev/null
}

@test "restapi is listening on the port" {
netstat -lnpt | grep 5000
}

@test "restapi is responding with data" {
wget -q -O - http://127.0.0.1:5000/api/v0.1/mon_status | grep quorum > /dev/null
}

0 comments on commit 3337ba4

Please sign in to comment.