Revision ff0d18e6 test/ganeti.cmdlib_unittest.py

b/test/ganeti.cmdlib_unittest.py
1 1
#!/usr/bin/python
2 2
#
3 3

  
4
# Copyright (C) 2008 Google Inc.
4
# Copyright (C) 2008, 2011 Google Inc.
5 5
#
6 6
# This program is free software; you can redistribute it and/or modify
7 7
# it under the terms of the GNU General Public License as published by
......
85 85
        self.cfg = mocks.FakeConfig()
86 86
        self.op = opcode
87 87

  
88
    class TestOpcode(opcodes.OpCode):
89
      OP_ID = "OP_TEST"
90
      OP_PARAMS = [
88
    class OpTest(opcodes.OpCode):
89
       OP_PARAMS = [
91 90
        ("iallocator", None, ht.NoType),
92 91
        ("node", None, ht.NoType),
93 92
        ]
......
95 94
    default_iallocator = mocks.FakeConfig().GetDefaultIAllocator()
96 95
    other_iallocator = default_iallocator + "_not"
97 96

  
98
    op = TestOpcode()
97
    op = OpTest()
99 98
    lu = TestLU(op)
100 99

  
101 100
    c_i = lambda: cmdlib._CheckIAllocatorOrNode(lu, "iallocator", "node")

Also available in: Unified diff