Skip to contentSkip to conversation

tests: add missing -display none to qtests

PATCH Applied Stefan Hajnoczi 2 participants 2 messages Nov 14, 2013 – Nov 18, 2013

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tests: add missing -display none to qtests

Commit 7ceeedd016facf8d58e14a0d1417fa7225d71072 ("blockdev-test: add test case for drive_add duplicate IDs") and commit 43cd209803d6cffb1e1a028c9ff2fd0ff4fce954 ("qdev-monitor-test: add device_add leak test cases") added qtest tests without specifying -display none.

As a result, "make check" now tries to use graphics (GTK or SDL). Since graphics are not used by the test and inappropriate for headless "make check" runs, add the missing -display none.

This fixes "make check" in the QEMU buildbot.

---
 tests/blockdev-test.c     | 2 +-
 tests/qdev-monitor-test.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
tests/blockdev-test.c +1 -1
index c940e00..fa49e09 100644
@@ -20,7 +20,7 @@ static void test_drive_add_empty(void)
     const char *response_return;
 
     /* Start with an empty drive */
-    qtest_start("-drive if=none,id=drive0");
+    qtest_start("-display none -drive if=none,id=drive0");
 
     /* Delete the drive */
     response = qmp("{\"execute\": \"human-monitor-command\","
tests/qdev-monitor-test.c +1 -1
index 33a8ea4..091ea5b 100644
@@ -20,7 +20,7 @@ static void test_device_add(void)
     QDict *response;
     QDict *error;
 
-    qtest_start("-drive if=none,id=drive0");
+    qtest_start("-display none -drive if=none,id=drive0");
 
     /* Make device_add fail.  If this leaks the virtio-blk-pci device then a
      * reference to drive0 will also be held (via qdev properties).
Signature · 1 line
1.8.3.1
#1 lore raw
Quoted 10 lines · Stefan Hajnoczi

Commit 7ceeedd016facf8d58e14a0d1417fa7225d71072 ("blockdev-test: add test case for drive_add duplicate IDs") and commit 43cd209803d6cffb1e1a028c9ff2fd0ff4fce954 ("qdev-monitor-test: add device_add leak test cases") added qtest tests without specifying -display none.

As a result, "make check" now tries to use graphics (GTK or SDL). Since graphics are not used by the test and inappropriate for headless "make check" runs, add the missing -display none.

Quoted 7 lines

This fixes "make check" in the QEMU buildbot.

---
 tests/blockdev-test.c     | 2 +-
 tests/qdev-monitor-test.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Applied to my block tree:
https://github.com/stefanha/qemu/commits/block

Stefan