[systemd-devel] [PATCH] initial sysv-generator test suite
Dimitri John Ledkov
dimitri.j.ledkov at intel.com
Tue Jan 20 10:23:18 PST 2015
On 20 January 2015 at 16:49, Martin Pitt <martin.pitt at ubuntu.com> wrote:
> Zbigniew Jędrzejewski-Szmek [2015-01-20 16:48 +0100]:
>> Maybe we could do this check in configure.ac/Makefile.am (add the test
>> to the list conditinally)?
>
> Yes, that's a good idea.
>
>> We already test for python presence and extract the version, so we
>> shouldn't duplicate the tests here and have an extra wrapper.
>
> Unfortunately automake's TESTS only accepts single arguments, i. e.
> scripts without any arguments. But we need to call $(PYTHON) test/x.py
> thus we need an argument.
>
With parallel test harness in automake (everyone should have it by
now) you can set custom "runner" of your test, based on extensions,
e.g. from automake manual:
TESTS = foo.pl bar.py baz
TEST_EXTENSIONS = .pl .py
PL_LOG_COMPILER = $(PERL)
AM_PL_LOG_FLAGS = -w
PY_LOG_COMPILER = $(PYTHON)
AM_PY_LOG_FLAGS = -v
LOG_COMPILER = ./wrapper-script
AM_LOG_FLAGS = -d
If above is not enough hint, i can poke automake-foo to support
$(PYTHON) tests when $(PYTHON) is available.
> An alternative would be to add a new
>
> TESTS_PYTHON = test/sysv-generator-test.py test/rule-syntax-check.py
>
> (and perhaps more in the future)
>
> and integrate that into Makefile.am. That would make Makefile.am more
> complex, but avoid the extra wrappers.
>
> WDYT?
>
> Thanks,
>
> Martin
> --
> Martin Pitt | http://www.piware.de
> Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)
> _______________________________________________
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
Regards,
Dimitri.
Intel Corporation (UK) Ltd. - Co. Reg. #1134945 - Pipers Way, Swindon SN3 1RJ.
More information about the systemd-devel
mailing list