Update IPMI driver for new base class.

Fix IPMI unit tests, and add missing power states and exceptions.
This commit is contained in:
Devananda van der Veen 2013-05-13 00:51:36 -07:00
parent 3bbaa8c922
commit accdc459ae
2 changed files with 21 additions and 1 deletions

View File

@ -31,7 +31,7 @@ from oslo.config import cfg
from ironic.common import safe_utils from ironic.common import safe_utils
from ironic.openstack.common import excutils from ironic.openstack.common import excutils
from ironic.openstack.common import log as logging from ironic.openstack.common import log as logging
from ironic.openstack.common.gettextutils import _
LOG = logging.getLogger(__name__) LOG = logging.getLogger(__name__)
@ -234,3 +234,7 @@ class NodeNotFound(NotFound):
class InterfaceNotFound(NotFound): class InterfaceNotFound(NotFound):
message = _("Interface %(iface)s could not be found.") message = _("Interface %(iface)s could not be found.")
class PowerStateFailure(IronicException):
message = _("Failed to set node power state to %(pstate)s.")

View File

@ -0,0 +1,16 @@
# vim: tabstop=4 shiftwidth=4 softtabstop=4
# Copyright 2013 Hewlett-Packard Development Company, L.P.
# All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.