History | View | Annotate | Download (19.1 kB)
qemu-iotests: make assert_no_active_block_jobs() common
Tests 030 and 041 both use query-block-jobs to check whether any blockjobs are active. Make this code common so that 'drive-backup' and othernew feature tests will be able to reuse it.
Suggested-by: Kevin Wolf <kwolf@redhat.com>...
qemu-iotests: make cancel_and_wait() common
The cancel_and_wait() function has been duplicated in 030 and 041. Moveit into iotests.py and let it return the event so tests can performadditional asserts.
Note that 041's cancel_and_wait(wait_ready=True) is replaced by...
qemu-iotests: make create_image() common
Both 030 and 041 use create_image(). Move it to iotests.py.
Also drop ImageStreamingTestCase since the class now has no methods.
Suggested-by: Kevin Wolf <kwolf@redhat.com>Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>...
qemu-iotests: add tests for streaming error handling
Add a test for each of report/ignore/stop. The tests use blkdebugto generate an error in the middle of a script. The error isrecoverable (once = "on") so that we can test resuming a job afterstopping for an error....
qemu-iotests: add test for pausing a streaming operation
These check that a paused streaming job does not advance its offset.
Sometimes the new test fails; the map is different between the sourceand the destination of the streaming because qemu-io does not always...
qemu-iotests: add backing file smaller than image test case
This new test case checks that streaming completes successfully when thebacking file is smaller than the image file.
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>...
qemu-iotests: Fix 030 after switch to GenericError
Signed-off-by: Kevin Wolf <kwolf@redhat.com>Reviewed-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
qemu-iotests: fill streaming test image with data
The TestStreamStop test case is racy; if the job completes before we cancancel it, it fails. If we remove the sleep the job will be canceledbefore it has even started, and the test succeeds but it is also not...
qemu-iotests: start vms in qtest mode
This way, they will not execute any VM code at all. However, right nowthe cancellation test is "relying" on being slowed down by TCG executingBIOS code. So, change the timeouts.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>...
stream: do not copy unallocated sectors from the base
Unallocated sectors should really never be accessed by the guest,so there's no need to copy them during the streaming process.If they are read by the guest during streaming, guest-initiatedcopy-on-read will copy them (we're in the base == NULL case, which...
stream: add testcase for partial streaming
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Kevin Wolf <kwolf@redhat.com>
stream: fix sectors not allocated test
The test on sectors not allocated can fail if the L1/L2 tables arenot on disk yet. Allow tests to shutdown the VM early.
qemu-iotests: add block-stream speed value test case
Add tests to exercise the InvalidParameter 'speed' error code path, aswell as the regular success case for setting the speed. Theblock-stream 'speed' parameter allows the speed limit of the job to be...
qmp: make block job command naming consistent
The block streaming and job commands used '_' instead of '-' for reasonsof compatibility with libvirt, which already included support for the'_' naming. However, the semantics of block_job_cancel have changed and...
test: add image streaming tests
This patch adds a test suite for the image streaming feature. Itexercises the 'block_stream', 'block_job_cancel', 'block_job_set_speed',and 'query-block-jobs' QMP commands.
Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>...