[libvirt] [dbus PATCH 3/3] tests: Use AM_TESTS_ENVIRONMENT

Andrea Bolognani posted 3 patches 7 years, 7 months ago
There is a newer version of this series
[libvirt] [dbus PATCH 3/3] tests: Use AM_TESTS_ENVIRONMENT
Posted by Andrea Bolognani 7 years, 7 months ago
According to the documentation[1], TESTS_ENVIRONMENT
is reserved for the user, which means we shouldn't be
using it.

AM_TESTS_ENVIRONMENT needs to be terminated with a
semicolon, so do that; that requires exporting the
variables instead of merely declaring them as well.

[1] https://www.gnu.org/software/automake/manual/html_node/Scripts_002dbased-Testsuites.html

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
---
 tests/Makefile.am | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/Makefile.am b/tests/Makefile.am
index 81cb263..e27a24a 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -36,5 +36,5 @@ EXTRA_DIST = \
 
 TESTS = $(test_programs)
 
-TESTS_ENVIRONMENT = \
-	VIRT_DBUS_INTERFACES_DIR=$(abs_top_builddir)/data
+AM_TESTS_ENVIRONMENT = \
+	export VIRT_DBUS_INTERFACES_DIR=$(abs_top_builddir)/data;
-- 
2.17.1

--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [dbus PATCH 3/3] tests: Use AM_TESTS_ENVIRONMENT
Posted by Pavel Hrdina 7 years, 7 months ago
On Wed, Jun 20, 2018 at 02:20:29PM +0200, Andrea Bolognani wrote:
> According to the documentation[1], TESTS_ENVIRONMENT
> is reserved for the user, which means we shouldn't be
> using it.
> 
> AM_TESTS_ENVIRONMENT needs to be terminated with a
> semicolon, so do that; that requires exporting the
> variables instead of merely declaring them as well.
> 
> [1] https://www.gnu.org/software/automake/manual/html_node/Scripts_002dbased-Testsuites.html
> 
> Signed-off-by: Andrea Bolognani <abologna@redhat.com>
> ---
>  tests/Makefile.am | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/tests/Makefile.am b/tests/Makefile.am
> index 81cb263..e27a24a 100644
> --- a/tests/Makefile.am
> +++ b/tests/Makefile.am
> @@ -36,5 +36,5 @@ EXTRA_DIST = \
>  
>  TESTS = $(test_programs)
>  
> -TESTS_ENVIRONMENT = \
> -	VIRT_DBUS_INTERFACES_DIR=$(abs_top_builddir)/data
> +AM_TESTS_ENVIRONMENT = \
> +	export VIRT_DBUS_INTERFACES_DIR=$(abs_top_builddir)/data;

This will need to be modified to cover the original environment
variables but otherwise looks good.

Pavel
--
libvir-list mailing list
libvir-list@redhat.com
https://www.redhat.com/mailman/listinfo/libvir-list