Commit 45a3721b authored by Stavros Sachtouris's avatar Stavros Sachtouris
Browse files

Fix functional test when there are no sharers

This error apears in pithos livetest account_get, when there are no sharer accounts
parent 6acfcec4
......@@ -42,6 +42,7 @@ class Astakos(livetest.Generic):
self.cloud = 'cloud.%s' % self['testcloud']
self.client = AstakosClient(
self[self.cloud, 'url'], self[self.cloud, 'token'])
print 'WHA?', self['astakos', 'details']
with open(self['astakos', 'details']) as f:
self._astakos_details = eval(f.read())
......
......@@ -224,7 +224,12 @@ class Pithos(livetest.Generic):
"""Check sharing_accounts"""
r = self.client.get_sharing_accounts()
self.assertTrue(len(r) > 0)
try:
self.assertTrue(len(r) > 0)
except AssertionError as e:
print '\n\tWARNING: Are there any sharers to your account?'
self.assertEqual(len(r), 0)
print '\tIf there are, this (%s) is an error, else it is OK' % e
def test_account_post(self):
"""Test account_POST"""
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment