diff options
Diffstat (limited to 'clientlib.py')
-rw-r--r-- | clientlib.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/clientlib.py b/clientlib.py index b9a348a..02ba4c8 100644 --- a/clientlib.py +++ b/clientlib.py @@ -38,7 +38,7 @@ def treedata_from_url(url): class IRBClient(BaseClient): def get_tests(self): - '''Return the list of known tests''' + '''Returns a list of known tests''' r = self.send_request('/get_tests') if 'tests' in r: return r['tests'] @@ -57,7 +57,8 @@ class IRBClient(BaseClient): def add_tree(self, *args, **kw): '''Add a new tree to israwhidebroken. Required arguments: arch, compose_id - Optional: tree_time, repodata_time''' + Optional: tree_time, repodata_time + Returns the new tree.''' for field in ('arch', 'compose_id', 'tree_time', 'repodata_time'): if field not in kw: raise ValueError, "Missing required arg %s" % field @@ -70,7 +71,7 @@ class IRBClient(BaseClient): pass # FIXME raise an exception or something def add_result(self, treeid, testid, result, detail_url=None): - '''Add a test result to the database''' + '''Add a test result to the database. Returns result id on success.''' params = {'treeid':treeid, 'testid':testid, 'result': result} if detail_url: params['detail_url'] = detail_url @@ -90,7 +91,9 @@ class IRBClient(BaseClient): more of (compose_id, tree_time, repodata_time) If add_tree is True and tree_data does not match any known tree, a new - tree will be added.''' + tree will be added. + + Returns result id on success.''' treelist = self.get_trees(**tree_data) if not treelist: if not add_tree: |