]> git-server-git.apps.pok.os.sepia.ceph.com Git - teuthology.git/commitdiff
Console: rename has_credentials 944/head
authorZack Cerza <zack@redhat.com>
Mon, 29 Aug 2016 23:02:15 +0000 (17:02 -0600)
committerZack Cerza <zack@redhat.com>
Mon, 29 Aug 2016 23:02:15 +0000 (17:02 -0600)
... to has_ipmi_credentials

Signed-off-by: Zack Cerza <zack@redhat.com>
teuthology/orchestra/console.py
teuthology/task/console_log.py
teuthology/test/task/test_console_log.py

index e32acd6ec2c30bda6eb2a9afca701fbd74049f4b..306f8fb32cd7c66a16c22cf003e7fe908754433d 100644 (file)
@@ -32,13 +32,13 @@ class PhysicalConsole():
         self.ipmiuser = ipmiuser or config.ipmi_user
         self.ipmipass = ipmipass or config.ipmi_password
         self.ipmidomain = ipmidomain or config.ipmi_domain
-        self.has_credentials = all(map(
+        self.has_ipmi_credentials = all(map(
             lambda x: x is not None,
             [self.ipmiuser, self.ipmipass, self.ipmidomain]
         ))
 
     def _check_credentials(self):
-        if not self.has_credentials:
+        if not self.has_ipmi_credentials:
             log.error(
                 "Must set ipmi_user, ipmi_password, and ipmi_domain in " \
                 ".teuthology.yaml"
index 2624aed2e332ca3a02bb60270b3b6b753b86574b..c8ace9cc45986f36814d69540082519b2448fc59 100644 (file)
@@ -28,7 +28,7 @@ class ConsoleLog(Task):
             if not hasattr(remote.console, 'spawn_sol_log'):
                 log.debug("%s does not support IPMI; excluding",
                           remote.shortname)
-            elif not remote.console.has_credentials:
+            elif not remote.console.has_ipmi_credentials:
                 log.debug("IPMI credentials not found for %s; excluding",
                           remote.shortname)
             else:
index e16eec2691091229cb45e40f61684e57e8202df8..e96dee9e283997049d5bdb4a824329e5e7ce0c41 100644 (file)
@@ -49,9 +49,9 @@ class TestConsoleLog(TestTask):
         task = self.klass(self.ctx, self.task_config)
         assert task.enabled is False
 
-    def test_has_credentials(self):
+    def test_has_ipmi_credentials(self):
         for remote in self.ctx.cluster.remotes.keys():
-            remote.console.has_credentials = False
+            remote.console.has_ipmi_credentials = False
         task = self.klass(self.ctx, self.task_config)
         assert len(task.cluster.remotes.keys()) == 0