diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2017-01-03 19:21:09 +0100 |
---|---|---|
committer | Marc-André Lureau <marcandre.lureau@redhat.com> | 2017-05-04 15:34:42 +0400 |
commit | e24ef0db4fabfe1f64854cfd2a2b5aaddc90f379 (patch) | |
tree | b0ac6280288e5ed1e33e9f09d64a4f359e5e9189 /tests/test-char.c | |
parent | e0b6767b6c56a08827e35873e7d259d08e4b3ee5 (diff) | |
download | qemu-e24ef0db4fabfe1f64854cfd2a2b5aaddc90f379.zip qemu-e24ef0db4fabfe1f64854cfd2a2b5aaddc90f379.tar.gz qemu-e24ef0db4fabfe1f64854cfd2a2b5aaddc90f379.tar.bz2 |
tests: add alias check in /char/ringbuf
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Diffstat (limited to 'tests/test-char.c')
-rw-r--r-- | tests/test-char.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test-char.c b/tests/test-char.c index 71de4b3..2811644 100644 --- a/tests/test-char.c +++ b/tests/test-char.c @@ -104,6 +104,16 @@ static void char_ringbuf_test(void) qemu_chr_fe_deinit(&be); object_unparent(OBJECT(chr)); + + /* check alias */ + opts = qemu_opts_create(qemu_find_opts("chardev"), "memory-label", + 1, &error_abort); + qemu_opt_set(opts, "backend", "memory", &error_abort); + qemu_opt_set(opts, "size", "2", &error_abort); + chr = qemu_chr_new_from_opts(opts, NULL); + g_assert_nonnull(chr); + object_unparent(OBJECT(chr)); + qemu_opts_del(opts); } static void char_mux_test(void) |