Commit graph

8 commits

Author SHA1 Message Date
Fabiano Rosas
de8bc62cc4 tests/qtest/migration: Split validation tests + misc
Move the remaining tests into a misc-tests.c file. These tests are
mostly about validation of input and should be in the future replaced
by unit testing.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:42 -03:00
Fabiano Rosas
44bd87a500 tests/qtest/migration: Split CPR tests
Move the mode/reboot test into a separate file to hold all the CPR
tests. Currently there's just one test, but we're adding more CPR
modes and the feature is different enough from live migration that
it's worth it to have a separate file for it.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:41 -03:00
Fabiano Rosas
8a64554456 tests/qtest/migration: Split precopy tests
Split the precopy tests from migration-test.c. This is the largest
group of tests and the more difficult one to break into smaller
groups, so move all of it.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:41 -03:00
Fabiano Rosas
d8057eb305 tests/qtest/migration: Split file tests
Split the file tests from migration-test.c. These are being moved to
their own file due to being special enough compared with the regular
stream migration. There is also the entire mapped-ram feature which
depends on file migration.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:41 -03:00
Fabiano Rosas
5e87cf322f tests/qtest/migration: Split postcopy tests
Split the next group of tests from migration-test.c, the postcopy
tests. This is another well-defined group of tests and postcopy is a
unique enough feature that it deserves it's own file.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:41 -03:00
Fabiano Rosas
932f74f3fe tests/qtest/migration: Split compression tests from migration-test.c
Continuing the split of groups of tests from migration-test.c, split
the compression tests into their own file.

Reviewed-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:41 -03:00
Fabiano Rosas
979ee2a76f tests/qtest/migration: Split TLS tests from migration-test.c
The migration-test.c file has become unwieldy large. It's quite
confusing to navigate with all the test definitions mixed with hook
definitions. The TLS tests make this worse with ifdef'ery.

Since we're planning on having a smaller set of tests to run as smoke
testing on all architectures, I'm taking the time to split some tests
into their own file.

Move the TLS tests into a file of their own.

Acked-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:40 -03:00
Fabiano Rosas
e1803dabdc tests/qtest/migration: Move common test code
The migration tests have a set of core infrastructure routines. These
are functions that are called by (almost) all tests and centralize the
common operations of: starting migration on both sides, waiting for
guests to boot, performing guest initialization and teardown, guest
memory validation, etc.

Move this basic framework code (and a few static helpers) into a
separate file. Leave only individual test functions (and their own
static helpers) in migration-test.c.

Acked-by: Peter Xu <peterx@redhat.com>
Signed-off-by: Fabiano Rosas <farosas@suse.de>
2024-12-12 10:25:40 -03:00