iotests: Add "add_drive_raw" method

This offers full manual control over the "-drive" options.

Signed-off-by: Fam Zheng <famz@redhat.com>
Message-id: 1448962590-2842-3-git-send-email-famz@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
This commit is contained in:
Fam Zheng 2015-12-01 17:36:29 +08:00 committed by Stefan Hajnoczi
parent 61408b250e
commit 78b666f46b

View File

@ -140,6 +140,11 @@ class VM(object):
self._args.append('-monitor')
self._args.append(args)
def add_drive_raw(self, opts):
self._args.append('-drive')
self._args.append(opts)
return self
def add_drive(self, path, opts='', interface='virtio'):
'''Add a virtio-blk drive to the VM'''
options = ['if=%s' % interface,