ignore result of slice_fs_deleted
[tests.git] / system / TestSliceSfa.py
index 97ac883..5de9f78 100644 (file)
@@ -22,9 +22,10 @@ class TestSliceSfa:
         # shortcuts
         self.test_plc=self.test_auth_sfa.test_plc
 
-    def qualified(self,name): return self.test_auth_sfa.qualified(name)
-    def hrn (self): return self.qualified(self.slice_spec['name'])
-    def sfi_path (self): return self.test_auth_sfa.sfi_path()
+    def hrn (self): 
+        return self.test_auth_sfa.obj_hrn(self.slice_spec['name'])
+    def sfi_path (self):
+        return self.test_auth_sfa.sfi_path()
 
     # send back up to the TestAuthSfa
     def rspec_style (self): return self.test_auth_sfa.rspec_style()
@@ -32,18 +33,18 @@ class TestSliceSfa:
     def sfi_user(self,*args,**kwds): return self.test_auth_sfa.sfi_user(*args, **kwds)
 
     def discover_option(self):
-        if self.rspec_style()=='pg': return "-r protogeni"
+        if self.rspec_style()=='pg': return "-r GENI"
         else:                        return "-r sfa"
 
     # those are step names exposed as methods of TestPlc, hence the _sfa
 
     # needs to be run as pi
-    def sfa_add_slice(self,options):
-        "run sfi add (on Registry)"
-        sfi_command="add"
+    def sfa_register_slice(self,options):
+        "run sfi register (on Registry)"
+        sfi_command="register"
         sfi_command += " --type slice"
         sfi_command += " --xrn %s"%self.hrn()
-        for opt in self.slice_spec['add_options']:
+        for opt in self.slice_spec['register_options']:
             sfi_command += " %s"%(opt)
        return self.test_plc.run_in_guest(self.sfi_pi(sfi_command))==0
 
@@ -86,7 +87,8 @@ class TestSliceSfa:
             "sfiListNodes.py -i %s/%s -o %s/%s"%(self.sfi_path(),self.adfile(),self.sfi_path(),self.nodefile()),
             "sfiAddSliver.py -i %s/%s -n %s/%s -o %s/%s"%\
                 (self.sfi_path(),self.adfile(),self.sfi_path(),self.nodefile(),self.sfi_path(),self.reqfile()),
-            self.sfi_user("create %s %s"%(self.hrn(),self.reqfile())),
+            self.sfi_user("allocate %s %s"%(self.hrn(),self.reqfile())),
+            self.sfi_user("provision %s"%(self.hrn())),
             ]
         for command in commands:
             if self.test_plc.run_in_guest(command)!=0: return False
@@ -137,7 +139,7 @@ class TestSliceSfa:
         command="echo hostname ; hostname; echo id; id; echo uname -a ; uname -a"
         
         tasks=[]
-        slicename=self.slice_spec['name']
+        slicename=self.plc_name()
         dry_run = getattr(options,'dry_run',False)
         for nodename in self.slice_spec['nodenames']:
             (site_spec,node_spec) = self.test_plc.locate_node(nodename)