oops - revert 16935 except for TestPlc - this was not intended to be committed
authorThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Wed, 3 Feb 2010 07:43:00 +0000 (07:43 +0000)
committerThierry Parmentelat <thierry.parmentelat@sophia.inria.fr>
Wed, 3 Feb 2010 07:43:00 +0000 (07:43 +0000)
system/LocalTestResources.sample.inria
system/LocalTestResources.sample.princeton
system/TestResources.py

index 5683087..c8d8b1f 100644 (file)
@@ -1,4 +1,4 @@
-# -*-python-*-
+#
 # $Id$
 # 
 # this is only an example file
@@ -28,18 +28,19 @@ class OnelabTestResources (TestResources):
                    '138.96.255.%d'%(230+i), 
                    '02:34:56:00:00:%02d'%i) for i in range(1,10) ]
     
-    # 64-bits qemu boxes that can run any test
-    def qemus_ip_pool_64 (self):
-        return [ ( 'testqemu%d.onelab.eu'%i, None, None) for i in range(1,4) ] 
+    def qemus_ip_pool (self):
+        return [ ( 'testqemu%d.onelab.eu'%i, None, None) for i in range(1,4) ]
 
-    # 32-bits qemu boxes that can run only 32bits nodes
-    def qemus_ip_pool_32 (self):
-        return [ ( 'testqemu32-%d.onelab.eu'%i, None, 32) for i in range(1,6) ]
+    def max_qemus (self):
+        return 3
 
     def plcs_ip_pool (self):
         return [  ( 'vplc%02d.inria.fr'%i, 
                     '138.96.255.%d'%(200+i), 
                     '02:34:56:00:ee:%02d'%i) for i in range(1,16) ]
 
+    def max_plcs (self):
+        return 12
+
 
 local_resources = OnelabTestResources ()
index 26c79fe..cbd08f5 100644 (file)
@@ -1,4 +1,4 @@
-# -*-python-*-
+#
 # $Id$
 # 
 # this is only an example file
@@ -28,10 +28,11 @@ class OnelabTestResources (TestResources):
                  ("node-02.test.planet-lab.org", "128.112.139.66", "de:ad:be:ef:00:20"),
                  ]
     
-    def qemus_ip_pool_64 (self):
+    def qemus_ip_pool (self):
         return [  ( 'testqemu1.test.planet-lab.org', None, None ) ]
-    def qemus_ip_pool_32 (self):
-        return [ ]
+
+    def max_qemus (self):
+        return 1
 
     def plcs_ip_pool (self):
         return [ ("plc-01.test.planet-lab.org","128.112.139.34", "de:ad:be:ef:ff:01"),
@@ -41,4 +42,8 @@ class OnelabTestResources (TestResources):
                  ("plc-05.test.planet-lab.org","128.112.139.41", "de:ad:be:ef:ff:05"),
                  ]
 
+    def max_plcs (self):
+        return 4
+
+
 local_resources = OnelabTestResources ()
index 53dee4f..0041404 100644 (file)
@@ -37,13 +37,6 @@ class TestResources:
             sys.exit(1)
         return plcs
 
-    def qemus_ip_pool(self):
-        return self.qemus_ip_pool_64()
-    def max_qemus(self):
-        return len(self.qemus_ip_pool())
-    def max_plcs(self):
-        return len(self.plcs_ip_pool())
-
     def localize_qemus (self,plcs,options):
 
         # all plcs on the same vserver box
@@ -180,13 +173,13 @@ class TestResources:
 
     ###
     def trplc_record (self,plc):
-        tracker = TrackerPlc(plc.options,instances=self.max_plcs()-1)
+        tracker = TrackerPlc(plc.options,instances=self.max_plcs())
         tracker.record(plc.test_ssh.hostname,plc.vservername)
         tracker.store()
         return True
 
     def trplc_free (self,plc):
-        tracker = TrackerPlc(plc.options,instances=self.max_plcs()-1)
+        tracker = TrackerPlc(plc.options,instances=self.max_plcs())
         tracker.free()
         tracker.store()
         return True
@@ -201,7 +194,7 @@ class TestResources:
         return True
 
     def trplc_cleanup (self,plc):
-        tracker = TrackerPlc(plc.options,instances=self.max_plcs()-1)
+        tracker = TrackerPlc(plc.options,instances=self.max_plcs())
         tracker.cleanup()
         tracker.store()
         return True
@@ -211,7 +204,7 @@ class TestResources:
         return True
 
     def trplc_list (self,plc):
-        TrackerPlc(plc.options,instances=self.max_plcs()-1).list()
+        TrackerPlc(plc.options,instances=self.max_plcs()).list()
         return True
 
     def localize_rspec (self,plcs,options):