Merge "mke2fs: do not use full path"
This commit is contained in:
commit
22702048ae
|
@ -148,7 +148,7 @@ class RemoteClient(remote_client.RemoteClient):
|
||||||
self.exec_command('sudo umount %s' % mount_path)
|
self.exec_command('sudo umount %s' % mount_path)
|
||||||
|
|
||||||
def make_fs(self, dev_name, fs='ext4'):
|
def make_fs(self, dev_name, fs='ext4'):
|
||||||
cmd_mkfs = 'sudo /usr/sbin/mke2fs -t %s /dev/%s' % (fs, dev_name)
|
cmd_mkfs = 'sudo mke2fs -t %s /dev/%s' % (fs, dev_name)
|
||||||
try:
|
try:
|
||||||
self.exec_command(cmd_mkfs)
|
self.exec_command(cmd_mkfs)
|
||||||
except tempest.lib.exceptions.SSHExecCommandFailed:
|
except tempest.lib.exceptions.SSHExecCommandFailed:
|
||||||
|
|
|
@ -811,7 +811,7 @@ ValidationGroup = [
|
||||||
default="password",
|
default="password",
|
||||||
help="Password used to authenticate to an instance."),
|
help="Password used to authenticate to an instance."),
|
||||||
cfg.StrOpt('ssh_shell_prologue',
|
cfg.StrOpt('ssh_shell_prologue',
|
||||||
default="set -eu -o pipefail; PATH=$$PATH:/sbin;",
|
default="set -eu -o pipefail; PATH=$$PATH:/sbin:/usr/sbin;",
|
||||||
help="Shell fragments to use before executing a command "
|
help="Shell fragments to use before executing a command "
|
||||||
"when sshing to a guest."),
|
"when sshing to a guest."),
|
||||||
cfg.IntOpt('ping_size',
|
cfg.IntOpt('ping_size',
|
||||||
|
|
|
@ -88,7 +88,7 @@ class TestRemoteClient(base.TestCase):
|
||||||
# the information using gnu/linux tools.
|
# the information using gnu/linux tools.
|
||||||
|
|
||||||
def _assert_exec_called_with(self, cmd):
|
def _assert_exec_called_with(self, cmd):
|
||||||
cmd = "set -eu -o pipefail; PATH=$PATH:/sbin; " + cmd
|
cmd = "set -eu -o pipefail; PATH=$PATH:/sbin:/usr/sbin; " + cmd
|
||||||
self.ssh_mock.mock.exec_command.assert_called_with(cmd)
|
self.ssh_mock.mock.exec_command.assert_called_with(cmd)
|
||||||
|
|
||||||
def test_get_disks(self):
|
def test_get_disks(self):
|
||||||
|
|
Loading…
Reference in New Issue