Merge "Remove some dead code"

This commit is contained in:
Jenkins 2016-02-23 12:36:29 +00:00 committed by Gerrit Code Review
commit 6a90e2e726
6 changed files with 0 additions and 69 deletions

View File

@ -76,9 +76,6 @@ class LiveBlockMigrationTestJSON(base.BaseV2ComputeAdminTest):
if host != target_host:
return target_host
def _get_server_status(self, server_id):
return self._get_server_details(server_id)['status']
def _volume_clean_up(self, server_id, volume_id):
body = self.volumes_client.show_volume(volume_id)['volume']
if body['status'] == 'in-use':

View File

@ -31,7 +31,6 @@ class AbsoluteLimitsNegativeTestJSON(base.BaseV2ComputeTest):
def setup_clients(cls):
super(AbsoluteLimitsNegativeTestJSON, cls).setup_clients()
cls.client = cls.limits_client
cls.server_client = cls.servers_client
@test.attr(type=['negative'])
@test.idempotent_id('215cd465-d8ae-49c9-bf33-9c911913a5c8')

View File

@ -1,39 +0,0 @@
# 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.
import shlex
import subprocess
from oslo_log import log as logging
LOG = logging.getLogger(__name__)
def copy_file_to_host(file_from, dest, host, username, pkey):
dest = "%s@%s:%s" % (username, host, dest)
cmd = "scp -v -o UserKnownHostsFile=/dev/null " \
"-o StrictHostKeyChecking=no " \
"-i %(pkey)s %(file1)s %(dest)s" % {'pkey': pkey,
'file1': file_from,
'dest': dest}
args = shlex.split(cmd.encode('utf-8'))
subprocess_args = {'stdout': subprocess.PIPE,
'stderr': subprocess.STDOUT}
proc = subprocess.Popen(args, **subprocess_args)
stdout, stderr = proc.communicate()
if proc.returncode != 0:
LOG.error(("Command {0} returned with exit status {1},"
"output {2}, error {3}").format(cmd, proc.returncode,
stdout, stderr))
return stdout

View File

@ -47,7 +47,6 @@ class HTTPClient(object):
self.endpoint_scheme = endpoint_parts.scheme
self.endpoint_hostname = endpoint_parts.hostname
self.endpoint_port = endpoint_parts.port
self.endpoint_path = endpoint_parts.path
self.connection_class = self._get_connection_class(
self.endpoint_scheme)

View File

@ -50,8 +50,6 @@ class Manager(object):
creds = self.credentials
# Creates an auth provider for the credentials
self.auth_provider = get_auth_provider(creds, pre_auth=True)
# FIXME(andreaf) unused
self.client_attr_names = []
def get_auth_provider_class(credentials):

View File

@ -15,7 +15,6 @@
from oslo_log import log as logging
from tempest.common import waiters
from tempest import config
from tempest.scenario import manager
from tempest import test
@ -37,32 +36,10 @@ class BaremetalBasicOps(manager.BaremetalScenarioTest):
* Verifies SSH connectivity using created keypair via fixed IP
* Associates a floating ip
* Verifies SSH connectivity using created keypair via floating IP
* Verifies instance rebuild with ephemeral partition preservation
* Deletes instance
* Monitors the associated Ironic node for power and
expected state transitions
"""
def rebuild_instance(self, preserve_ephemeral=False):
self.rebuild_server(server_id=self.instance['id'],
preserve_ephemeral=preserve_ephemeral,
wait=False)
node = self.get_node(instance_id=self.instance['id'])
# We should remain on the same node
self.assertEqual(self.node['uuid'], node['uuid'])
self.node = node
waiters.wait_for_server_status(
self.servers_client,
server_id=self.instance['id'],
status='REBUILD',
ready_wait=False)
waiters.wait_for_server_status(
self.servers_client,
server_id=self.instance['id'],
status='ACTIVE')
def verify_partition(self, client, label, mount, gib_size):
"""Verify a labeled partition's mount point and size."""
LOG.info("Looking for partition %s mounted on %s" % (label, mount))