All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [RFC PATCH] configure: Enable out-of-tree acceptance tests
@ 2018-05-30 20:03 Philippe Mathieu-Daudé
  2018-05-30 23:25 ` Eduardo Habkost
  2018-05-31  1:06 ` Cleber Rosa
  0 siblings, 2 replies; 9+ messages in thread
From: Philippe Mathieu-Daudé @ 2018-05-30 20:03 UTC (permalink / raw)
  To: Fam Zheng, Eduardo Habkost, Amador Pahim, Cleber Rosa
  Cc: Philippe Mathieu-Daudé, qemu-devel

In order to allow out-of-tree acceptance tests with Avocado,
create a symlink in the build tree.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
Based-on: 20180530184156.15634-1-crosa@redhat.com
http://lists.nongnu.org/archive/html/qemu-devel/2018-05/msg06877.html

Before:

  build_dir$ avocado run /full/path/to/sources/qemu/tests/acceptance/boot_linux_console.py

After

  build_dir$ avocado run tests/acceptance/boot_linux_console.py

I first wanted to try something like:

echo "[datadir.paths]" > .avocado.conf
echo "test_dir = $source_path/tests/acceptance" >> .avocado.conf

to run:

  build_dir$ avocado run -t console

but this doesn't work this way, I'd have to use

  build_dir$ avocado --config .avocado.conf boot_linux_console.py -t console

which isn't a win.
---
 configure | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/configure b/configure
index a6a4616c3e..0763ebe5ba 100755
--- a/configure
+++ b/configure
@@ -7213,9 +7213,11 @@ for rom in seabios vgabios ; do
 done
 
 # set up tests data directory
-if [ ! -e tests/data ]; then
-    symlink "$source_path/tests/data" tests/data
-fi
+for tests_subdir in acceptance data; do
+    if [ ! -e tests/$tests_subdir ]; then
+        symlink "$source_path/tests/$tests_subdir" tests/$tests_subdir
+    fi
+done
 
 # set up qemu-iotests in this build directory
 iotests_common_env="tests/qemu-iotests/common.env"
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2018-06-06 23:20 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-30 20:03 [Qemu-devel] [RFC PATCH] configure: Enable out-of-tree acceptance tests Philippe Mathieu-Daudé
2018-05-30 23:25 ` Eduardo Habkost
2018-05-31  1:06 ` Cleber Rosa
2018-06-05 14:45   ` Philippe Mathieu-Daudé
2018-06-06 19:24     ` Eduardo Habkost
2018-06-06 19:36       ` Philippe Mathieu-Daudé
2018-06-06 20:11         ` Eduardo Habkost
2018-06-06 20:23           ` Cleber Rosa
2018-06-06 23:19             ` Philippe Mathieu-Daudé

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.