[elbe-devel] [PATCH 05/10] test_xml: actually try to build something using the pbuilder
Bastian Germann
bage at linutronix.de
Fri May 7 10:28:56 CEST 2021
Am 06.05.21 um 14:55 schrieb Torben Hohn:
> docs/quickstart.txt gives libgpio as an example.
>
> Clone it from github, and build it using pbuilder.
>
> While at it change the code in the vincinity to f strings.
Typo: vicinity
We should make sure not to use f strings (py3.6) for the elbe client if we want to stay compatible
with stretch (py3.5). In tests it is okay.
>
> Signed-off-by: Torben Hohn <torben.hohn at linutronix.de>
> ---
> elbepack/tests/test_xml.py | 13 ++++++-------
> 1 file changed, 6 insertions(+), 7 deletions(-)
>
> diff --git a/elbepack/tests/test_xml.py b/elbepack/tests/test_xml.py
> index 0f3069a37..5c4a7e16f 100644
> --- a/elbepack/tests/test_xml.py
> +++ b/elbepack/tests/test_xml.py
> @@ -67,16 +67,15 @@ class TestPbuilder(ElbeTestCase):
> uuid = None
>
> try:
> - system('%s pbuilder create --xmlfile "%s" --writeproject "%s"' %
> - (elbe_exe, self.param, prj))
> -
> - # TODO: checkout some source code
> + system(f'{elbe_exe} pbuilder create --xmlfile "{self.param} \
There is a quote missing after {self.param}.
> + --writeproject "{prj}"')
> + system(f'cd "{build_dir}"; \
> + git clone https://github.com/Linutronix/libgpio.git')
>
> with open(prj, "r") as f:
> uuid = f.read()
> - system('cd "%s"; %s pbuilder build --project %s' % (build_dir,
> - elbe_exe,
> - uuid))
> + system(f'cd "{build_dir}/libgpio"; \
> + {elbe_exe} pbuilder build --project {uuid}')
> # pylint: disable=try-except-raise
> except:
> raise
>
With typo and quote fixed
Reviewed-by: Bastian Germann <bage at linutronix.de>
More information about the elbe-devel
mailing list