From: Rishabh Dave Date: Fri, 19 Jul 2019 08:18:51 +0000 (+0530) Subject: qa/cephfs: make run_shell() accept args as str too X-Git-Tag: v15.1.0~2061^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F28793%2Fhead;p=ceph.git qa/cephfs: make run_shell() accept args as str too Signed-off-by: Rishabh Dave --- diff --git a/qa/tasks/cephfs/mount.py b/qa/tasks/cephfs/mount.py index 8fad4d8a4055..81d779cb8acb 100644 --- a/qa/tasks/cephfs/mount.py +++ b/qa/tasks/cephfs/mount.py @@ -184,6 +184,9 @@ class CephFSMount(object): def run_shell(self, args, wait=True, stdin=None, check_status=True, omit_sudo=True): + if isinstance(args, str): + args = args.split() + args = ["cd", self.mountpoint, run.Raw('&&'), "sudo"] + args return self.client_remote.run(args=args, stdout=StringIO(), stderr=StringIO(), wait=wait,