Skip to content
This repository has been archived by the owner on Jul 29, 2020. It is now read-only.

Commit

Permalink
test cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
cglewis committed Sep 15, 2013
1 parent 6098688 commit a79409a
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions hemlock/test_hemlock.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,8 @@ def process_client_list(self):
error.append(error2)
d, error3 = a.process_action(0, "register-local-system", {'--name':'local-system1', '--data_type':'data-type1', '--description': 'description1', '--tenant_id':c[2][1], '--hostname':'hostname1', '--endpoint':'http://endpoint.com/', '--poc_name':'poc-name1', '--poc_email':'poc-email@dot.com'}, m_server, "localhost")
error.append(error3)
# !! TODO
# need to figure out issue when credentials file
#e, error4 = a.process_action(0, "client-store", {'--name':'client1', '--type':'mysql', '--system_id':d[9][1], '--credential_file':'/foo'}, m_server, "localhost")
#error.append(error4)
e, error4 = a.process_action(0, "client-store", {'--name':'client1', '--type':'mysql', '--system_id':d[9][1], '--credential_file':'hemlock/clients/mysql_creds_sample'}, m_server, "localhost")
error.append(error4)
x, error5 = a.process_action(0, "client-list", {}, m_server, "localhost")
error.append(error5)
return x, error
Expand Down Expand Up @@ -116,17 +114,13 @@ def process_client_store(self):
error.append(error1)
c, error2 = a.process_action(0, "register-local-system", {'--name':'local-system1', '--data_type':'data-type1', '--description': 'description1', '--tenant_id':b[2][1], '--hostname':'hostname1', '--endpoint':'http://endpoint.com/', '--poc_name':'poc-name1', '--poc_email':'poc-email@dot.com'}, m_server, "localhost")
error.append(error2)
# !! TODO
# need to figure out issue when credentials file
x, error3 = a.process_action(0, "client-store", {'--name':'client1', '--type':'mysql', '--system_id':c[9][1], '--credential_file':'hemlock/clients/mysql_creds_sample'}, m_server, "localhost")
error.append(error3)
cur = m_server.cursor()
str = "select * from clients where uuid = '"+x[2][1]+"'"
cur.execute(str)
y = cur.fetchall()
return x, y, error
#x = ""
#return x, error

def process_schedule_get(self):
"""
Expand Down Expand Up @@ -1199,7 +1193,7 @@ def test_process_client_store(self):
"""
Calls the test function for the client-store action.
"""
x, error = self.process_client_store()
x, y, error = self.process_client_store()
for err in error:
assert err == 0

Expand Down

0 comments on commit a79409a

Please sign in to comment.