fixes
Thierry Parmentelat [Mon, 2 Jun 2008 20:03:37 +0000 (20:03 +0000)]
system/TestApiserver.py
system/TestNode.py
system/TestPlc.py

index 5d49a23..baf3c9a 100644 (file)
@@ -9,15 +9,12 @@ server_methods = [ ('GetNodes' ,  []),
                    ('UpdateNode' , True),
                    ('AddInterface' , True),
                    ('GetInterfaces' , True),
-                   ('GetInterfaceSettingTypes' , True),
-                   ('AddInterfaceSettingType' , True),
+                   ('GetTagTypes' , []),
+                   ('AddTagType' , True),
                    ('AddInterfaceSetting' , True),
                    ('GetBootMedium' , True),
                    ('GetNodeGroups' , True),
                    ('AddNodeGroup' , True),
-                   ('GetNodeTagTypes' , []),
-                   ('AddNodeTagType', True),
-                   ('AddNodeTag', True),
                    ('GetNodeTags', True),
                    ('AddInitScript' , True),
                    ('DeleteInitScript', True),
index 5b38823..05653fa 100644 (file)
@@ -84,10 +84,10 @@ class TestNode:
                         nnid=nn['interface_id']
                         # locate or create node network attribute type
                         try:
-                            nnst = server.GetInterfaceSettingTypes(userauth,{'name':attribute})[0]
+                            nnst = server.GetTagTypes(userauth,{'name':attribute})[0]
                         except:
-                            nnst = server.AddInterfaceSettingType(rootauth,{'category':'test',
-                                                                              'name':attribute})
+                            nnst = server.AddTagType(rootauth,{'category':'test',
+                                                               'tagname':attribute})
                         # attach value
                         server.AddInterfaceSetting(userauth,nnid,attribute,value)
 
index 4282417..4e9a99b 100644 (file)
@@ -441,7 +441,7 @@ class TestPlc:
         for (nodegroupname,group_nodes) in groups_dict.iteritems():
             print 'nodegroups:','dealing with nodegroup',nodegroupname,'on nodes',group_nodes
             # first, check if the nodetagtype is here
-            tag_types = self.apiserver.GetNodeTagTypes(auth,{'tagname':nodegroupname})
+            tag_types = self.apiserver.GetTagTypes(auth,{'tagname':nodegroupname})
             if tag_types:
                 tag_type_id = tag_types[0]['node_tag_type_id']
             else: