From patchwork Sat Jan 12 14:14:34 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jacopo Mondi X-Patchwork-Id: 213 Return-Path: Received: from relay2-d.mail.gandi.net (relay2-d.mail.gandi.net [217.70.183.194]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 7581F60C69 for ; Sat, 12 Jan 2019 15:14:35 +0100 (CET) X-Originating-IP: 2.224.242.101 Received: from uno.lan (2-224-242-101.ip172.fastwebnet.it [2.224.242.101]) (Authenticated sender: jacopo@jmondi.org) by relay2-d.mail.gandi.net (Postfix) with ESMTPSA id CB68140004; Sat, 12 Jan 2019 14:14:34 +0000 (UTC) From: Jacopo Mondi To: libcamera-devel@lists.libcamera.org Date: Sat, 12 Jan 2019 15:14:34 +0100 Message-Id: <20190112141436.1562-2-jacopo@jmondi.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190112141436.1562-1-jacopo@jmondi.org> References: <20190112141436.1562-1-jacopo@jmondi.org> MIME-Version: 1.0 Subject: [libcamera-devel] [PATCH v3 1/3] test: media_device: Convert to foreach X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Jan 2019 14:14:35 -0000 From: Kieran Bingham Prevent duplication of boilerplate code as the suite grows by establishing the foreach pattern in the media_device test suite. Signed-off-by: Kieran Bingham Signed-off-by: Jacopo Mondi --- test/media_device/meson.build | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/test/media_device/meson.build b/test/media_device/meson.build index a7ebed1..40f9ffa 100644 --- a/test/media_device/meson.build +++ b/test/media_device/meson.build @@ -1,5 +1,11 @@ -media_device_test = executable('media_device_test', 'media_device_test.cpp', - link_with : test_libraries, - include_directories : test_includes_internal) +media_device_tests = [ + ['media_device_test', 'media_device_test.cpp'], +] -test('Media Device Test', media_device_test) +foreach t : media_device_tests + exe = executable(t[0], t[1], + link_with : test_libraries, + include_directories : test_includes_internal) + + test(t[0], exe, suite: 'media_device', is_parallel: false) +endforeach