From b469eb4d7e729a7c27b471797001b932d4644f96 Mon Sep 17 00:00:00 2001
From: Iustin Pop <iustin@google.com>
Date: Sat, 15 Jan 2011 13:07:20 +0100
Subject: [PATCH] Rename OpTestJobqueue and LUTestJobqueue
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Iustin Pop <iustin@google.com>
Reviewed-by: RenΓ© Nussbaumer <rn@google.com>
Reviewed-by: Michael Hanselmann <hansmi@google.com>
---
 lib/client/gnt_debug.py        | 34 +++++++++++++++++-----------------
 lib/cmdlib.py                  |  2 +-
 lib/opcodes.py                 |  2 +-
 test/ganeti.cmdlib_unittest.py |  4 ++--
 4 files changed, 21 insertions(+), 21 deletions(-)

diff --git a/lib/client/gnt_debug.py b/lib/client/gnt_debug.py
index 37eeed526..39ee043ac 100644
--- a/lib/client/gnt_debug.py
+++ b/lib/client/gnt_debug.py
@@ -1,7 +1,7 @@
 #
 #
 
-# Copyright (C) 2006, 2007, 2010 Google Inc.
+# Copyright (C) 2006, 2007, 2010, 2011 Google Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -350,14 +350,14 @@ def TestJobqueue(opts, _):
     if mode == TM_PARTFAIL:
       ToStdout("Testing partial job failure")
       ops = [
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=False),
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=False),
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=True),
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=False),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=False),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=False),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=True),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=False),
         ]
       expect_messages = 3 * [test_messages]
       expect_opstatus = [
@@ -370,10 +370,10 @@ def TestJobqueue(opts, _):
     elif mode == TM_MULTISUCCESS:
       ToStdout("Testing multiple successful opcodes")
       ops = [
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=False),
-        opcodes.OpTestJobqueue(notify_waitlock=True, notify_exec=True,
-                               log_messages=test_messages, fail=False),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=False),
+        opcodes.OpTestJqueue(notify_waitlock=True, notify_exec=True,
+                             log_messages=test_messages, fail=False),
         ]
       expect_messages = 2 * [test_messages]
       expect_opstatus = [
@@ -392,10 +392,10 @@ def TestJobqueue(opts, _):
         raise errors.ProgrammerError("Unknown test mode %s" % mode)
 
       ops = [
-        opcodes.OpTestJobqueue(notify_waitlock=True,
-                               notify_exec=True,
-                               log_messages=test_messages,
-                               fail=fail)
+        opcodes.OpTestJqueue(notify_waitlock=True,
+                             notify_exec=True,
+                             log_messages=test_messages,
+                             fail=fail)
         ]
       expect_messages = [test_messages]
       expect_resultlen = 1
diff --git a/lib/cmdlib.py b/lib/cmdlib.py
index fdb7860fa..8bd6d649c 100644
--- a/lib/cmdlib.py
+++ b/lib/cmdlib.py
@@ -10582,7 +10582,7 @@ class LUTestDelay(NoHooksLU):
         self._TestDelay()
 
 
-class LUTestJobqueue(NoHooksLU):
+class LUTestJqueue(NoHooksLU):
   """Utility LU to test some aspects of the job queue.
 
   """
diff --git a/lib/opcodes.py b/lib/opcodes.py
index 85268a9aa..1d3179c6a 100644
--- a/lib/opcodes.py
+++ b/lib/opcodes.py
@@ -1262,7 +1262,7 @@ class OpTestAllocator(OpCode):
     ]
 
 
-class OpTestJobqueue(OpCode):
+class OpTestJqueue(OpCode):
   """Utility opcode to test some aspects of the job queue.
 
   """
diff --git a/test/ganeti.cmdlib_unittest.py b/test/ganeti.cmdlib_unittest.py
index 65a08fed9..234178958 100755
--- a/test/ganeti.cmdlib_unittest.py
+++ b/test/ganeti.cmdlib_unittest.py
@@ -133,9 +133,9 @@ class TestIAllocatorChecks(testutils.GanetiTestCase):
     self.assertRaises(errors.OpPrereqError, c_i)
 
 
-class TestLUTestJobqueue(unittest.TestCase):
+class TestLUTestJqueue(unittest.TestCase):
   def test(self):
-    self.assert_(cmdlib.LUTestJobqueue._CLIENT_CONNECT_TIMEOUT <
+    self.assert_(cmdlib.LUTestJqueue._CLIENT_CONNECT_TIMEOUT <
                  (luxi.WFJC_TIMEOUT * 0.75),
                  msg=("Client timeout too high, might not notice bugs"
                       " in WaitForJobChange"))
-- 
GitLab