X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=system%2FTestUserSfa.py;h=ccd07c399397f1f80ab44e7bf24da23caf884073;hb=ee198177f39ef59b1bfed86a2d7a09c9e8d1a976;hp=0ab2df6839cc7413efc754a5468c1549406914db;hpb=84c56ab4b28273e9f2a4b318895acb8224945fa9;p=tests.git diff --git a/system/TestUserSfa.py b/system/TestUserSfa.py index 0ab2df6..ccd07c3 100644 --- a/system/TestUserSfa.py +++ b/system/TestUserSfa.py @@ -22,26 +22,23 @@ class TestUserSfa: # xxx todo - not the right place any longer - or is it ? def add_user (self): - sfi_add_options = self.sfa_slice_spec['person_options'] + sfi_add_options = self.sfa_slice_spec['user_sfi_options'] + user_hrn = self.sfa_slice_spec['user_hrn'] command="sfi -d %s add"%(self.sfi_path()) - for (opt,val) in sfi_add_options.items(): - command += " %s %s"%(opt,val) + for opt in sfi_add_options: + command += " %s"%(opt,) # handle key separately because of embedded whitespace # hack - the user's pubkey is avail from his hrn - hrn=sfi_add_options['-x'] - command += " -k %s/%s.pub"%(self.sfi_path(),hrn) + command += " -k %s/%s.pub"%(self.sfi_path(),user_hrn) return self.test_plc.run_in_guest(command)==0 def update_user (self): # xxx TODO now that we use sfi arguments utils.header ("WARNING: TestUserSfa.update_user needs more work") return True -# return self.test_plc.run_in_guest("sfi.py -d %s update %s"% -# (self.sfi_path(),self.addpersonfile()))==0 def delete_user(self): auth=self.sfa_spec['SFA_REGISTRY_ROOT_AUTH'] return \ - self.test_plc.run_in_guest("sfi.py -d %s remove -t user %s.%s.%s"%( + self.test_plc.run_in_guest("sfi -d %s remove -t user %s.%s.%s"%( self.sfi_path(),auth,self.login_base,self.regularuser))==0 -