All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Dr. David Alan Gilbert" <dgilbert@redhat.com>
To: Balamuruhan S <bala24@linux.ibm.com>
Cc: ehabkost@redhat.com, groug@kaod.org, qemu-devel@nongnu.org,
	sathnaga@linux.vnet.ibm.com, clg@kaod.org, crosa@redhat.com,
	qemu-ppc@nongnu.org, david@gibson.dropbear.id.au
Subject: Re: [Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all machine types
Date: Mon, 16 Sep 2019 15:50:06 +0100	[thread overview]
Message-ID: <20190916144709.GD2884@work-vm> (raw)
In-Reply-To: <20190916093445.20507-4-bala24@linux.ibm.com>

* Balamuruhan S (bala24@linux.ibm.com) wrote:
> add migration test to query machine types supported by qemu binary
> and migrate vm will all supported type.
> 
> Signed-off-by: Balamuruhan S <bala24@linux.ibm.com>

Depending on the architecture you might find that some machine types
aren't migratable while some are.

Dave

> ---
>  tests/acceptance/migration.py | 26 ++++++++++++++++++++++++++
>  1 file changed, 26 insertions(+)
> 
> diff --git a/tests/acceptance/migration.py b/tests/acceptance/migration.py
> index 0f3553c8f0..74416ccc21 100644
> --- a/tests/acceptance/migration.py
> +++ b/tests/acceptance/migration.py
> @@ -49,3 +49,29 @@ class Migration(Test):
>          self.assertEqual(dest_vm.command('query-status')['status'], 'running')
>          self.assertEqual(source_vm.command('query-status')['status'],
>                           'postmigrate')
> +
> +
> +    def test_migration_with_machine_types(self):
> +        migration_port = self._get_free_port()
> +        for machine in self.get_machine_types():
> +            if 'pseries' in machine:
> +                print("migrating with machine type - {}".format(machine))
> +                source_vm = self.get_vm('-M', '{},cap-htm=off'.format(machine))
> +                dest_uri = 'tcp:localhost:%u' % migration_port
> +                dest_vm = self.get_vm('-M', '{},cap-htm=off'.format(machine),
> +                                      '-incoming', dest_uri)
> +                dest_vm.launch()
> +                source_vm.launch()
> +                source_vm.qmp('migrate', uri=dest_uri)
> +                wait.wait_for(
> +                    self.migration_finished,
> +                    timeout=self.timeout,
> +                    step=0.1,
> +                    args=(source_vm,)
> +                )
> +                self.assertEqual(source_vm.command('query-migrate')['status'],
> +                                                   'completed')
> +                self.assertEqual(dest_vm.command('query-status')['status'],
> +                                                 'running')
> +                self.assertEqual(source_vm.command('query-status')['status'],
> +                                                   'postmigrate')
> -- 
> 2.14.5
> 
> 
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK


  reply	other threads:[~2019-09-16 16:08 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-16  9:34 [Qemu-devel] [PATCH 0/3] Add acceptance test for migration Balamuruhan S
2019-09-16  9:34 ` [Qemu-devel] [PATCH 1/3] tests/acceptance/migration: fix post migration check Balamuruhan S
2019-09-16 18:50   ` Dr. David Alan Gilbert
2019-09-17  8:51     ` Balamuruhan S
2019-09-17  9:40       ` Dr. David Alan Gilbert
2019-09-16  9:34 ` [Qemu-devel] [PATCH 2/3] tests/acceptance/avocado_qemu: add method to get supported machine types Balamuruhan S
2019-09-16  9:34 ` [Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all " Balamuruhan S
2019-09-16 14:50   ` Dr. David Alan Gilbert [this message]
2019-09-17  8:45     ` Balamuruhan S
2019-09-17  9:44       ` Dr. David Alan Gilbert
2019-09-18  0:46         ` David Gibson
  -- strict thread matches above, loose matches on Subject: below --
2019-08-05 18:20 [Qemu-devel] [PATCH 0/3] Add acceptance test for migration Balamuruhan S
2019-08-05 18:20 ` [Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all machine types Balamuruhan S

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190916144709.GD2884@work-vm \
    --to=dgilbert@redhat.com \
    --cc=bala24@linux.ibm.com \
    --cc=clg@kaod.org \
    --cc=crosa@redhat.com \
    --cc=david@gibson.dropbear.id.au \
    --cc=ehabkost@redhat.com \
    --cc=groug@kaod.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    --cc=sathnaga@linux.vnet.ibm.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.