From: Leandro Ribeiro Date: Tue, 5 May 2020 19:09:03 +0000 (-0300) Subject: tests: don't use width and height for drm/fbdev backend tests X-Git-Tag: upstream/9.0.0~50 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=e8033e3dd166449ef1a91941fe0d6f8a2e59da45;p=platform%2Fupstream%2Fweston.git tests: don't use width and height for drm/fbdev backend tests In the test suite we have some default options which are command line arguments used by most of the tests. Two of these are width==320 and height==240. But when we have DRM or fbdev backends, width and height are not possible command line arguments. This makes impossible to run tests that uses one of these types of backends, as the compositor won't open if the command line string is wrong. Fix this by not passing command line arguments width and height if the backend is DRM or fbdev. Signed-off-by: Leandro Ribeiro --- diff --git a/tests/weston-test-fixture-compositor.c b/tests/weston-test-fixture-compositor.c index da0fa26a..1b2df97f 100644 --- a/tests/weston-test-fixture-compositor.c +++ b/tests/weston-test-fixture-compositor.c @@ -273,11 +273,14 @@ execute_compositor(const struct compositor_setup *setup, setup->extra_module ? setup->extra_module : ""); prog_args_take(&args, tmp); - asprintf(&tmp, "--width=%d", setup->width); - prog_args_take(&args, tmp); + if (setup->backend != WESTON_BACKEND_DRM && + setup->backend != WESTON_BACKEND_FBDEV) { + asprintf(&tmp, "--width=%d", setup->width); + prog_args_take(&args, tmp); - asprintf(&tmp, "--height=%d", setup->height); - prog_args_take(&args, tmp); + asprintf(&tmp, "--height=%d", setup->height); + prog_args_take(&args, tmp); + } if (setup->scale != 1) { asprintf(&tmp, "--scale=%d", setup->scale);