{"id":19418,"url":"https://patchwork.libcamera.org/api/patches/19418/?format=json","web_url":"https://patchwork.libcamera.org/patch/19418/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/projects/1/?format=json","name":"libcamera","link_name":"libcamera","list_id":"libcamera_core","list_email":"libcamera-devel@lists.libcamera.org","web_url":"","scm_url":"","webscm_url":""},"msgid":"<20240119200848.358298-2-nicolas@ndufresne.ca>","date":"2024-01-19T20:08:48","name":"[libcamera-devel,v2,2/2] test: gstreamer: Use env instead of registry edit","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"95c495a99ca7ba834cc26f2e453f5d024cb62cf9","submitter":{"id":30,"url":"https://patchwork.libcamera.org/api/people/30/?format=json","name":"Nicolas Dufresne","email":"nicolas@ndufresne.ca"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/19418/mbox/","series":[{"id":4146,"url":"https://patchwork.libcamera.org/api/series/4146/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=4146","date":"2024-01-19T20:08:47","name":"[libcamera-devel,v2,1/2] gstreamer: Add meson devenv support","version":2,"mbox":"https://patchwork.libcamera.org/series/4146/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/19418/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/19418/checks/","tags":{},"headers":{"Return-Path":"<libcamera-devel-bounces@lists.libcamera.org>","X-Original-To":"parsemail@patchwork.libcamera.org","Delivered-To":"parsemail@patchwork.libcamera.org","Received":["from lancelot.ideasonboard.com (lancelot.ideasonboard.com\n\t[92.243.16.209])\n\tby patchwork.libcamera.org (Postfix) with ESMTPS id B268CC323E\n\tfor <parsemail@patchwork.libcamera.org>;\n\tFri, 19 Jan 2024 20:09:14 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 678E161D4C;\n\tFri, 19 Jan 2024 21:09:14 +0100 (CET)","from madrid.collaboradmins.com (madrid.collaboradmins.com\n\t[IPv6:2a00:1098:ed:100::25])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 41C8361D3C\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tFri, 19 Jan 2024 21:09:12 +0100 (CET)","from nicolas-tpx395.lan (cola.collaboradmins.com [195.201.22.229])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\tkey-exchange X25519 server-signature RSA-PSS (4096 bits)\n\tserver-digest SHA256)\n\t(No client certificate requested) (Authenticated sender: nicolas)\n\tby madrid.collaboradmins.com (Postfix) with ESMTPSA id A31A6378042B; \n\tFri, 19 Jan 2024 20:09:11 +0000 (UTC)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org;\n\ts=mail; t=1705694954;\n\tbh=HvP1O5J7UkCfnfwhamMK0sBUkDJQnn6tDV1FlpaGbcc=;\n\th=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe:\n\tList-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To:Cc:\n\tFrom;\n\tb=uMutLT93qbAzTRCcxh1jGS/34sGz3aHnte1YvDOfKQLD0Q9GaX/6QHOlzPykZoHsy\n\tbye/sG2eDWRTcYB6XVof2MjcuKuPWwtFGxPBR0tLFSt6D0P0QchlLtZzaNDP2pvYQB\n\tcZx5HeZmPKe7dJbHJ2dSGdctBlX0h7Cz3aDLhSVT9wCR9tH4/WV0x2KeNIh2cwS2DZ\n\tdSWODnnG73VNUDabtfGaP7SUckjVlxacAgldVqU885UZBl4JTX/iVJ+aCdFs8lgODi\n\tZT9PUsew2FXqbSW/c17e02MQxPFTycs7afNZj+wuur2ra9gaaU/bhcA0L5YI2NRJwu\n\tfBCFZnf9gm4Iw==","To":"libcamera-devel@lists.libcamera.org","Date":"Fri, 19 Jan 2024 15:08:48 -0500","Message-ID":"<20240119200848.358298-2-nicolas@ndufresne.ca>","X-Mailer":"git-send-email 2.43.0","In-Reply-To":"<20240119200848.358298-1-nicolas@ndufresne.ca>","References":"<20240119200848.358298-1-nicolas@ndufresne.ca>","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","Subject":"[libcamera-devel] [PATCH v2 2/2] test: gstreamer: Use env instead\n\tof registry edit","X-BeenThere":"libcamera-devel@lists.libcamera.org","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"<libcamera-devel.lists.libcamera.org>","List-Unsubscribe":"<https://lists.libcamera.org/options/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=unsubscribe>","List-Archive":"<https://lists.libcamera.org/pipermail/libcamera-devel/>","List-Post":"<mailto:libcamera-devel@lists.libcamera.org>","List-Help":"<mailto:libcamera-devel-request@lists.libcamera.org?subject=help>","List-Subscribe":"<https://lists.libcamera.org/listinfo/libcamera-devel>,\n\t<mailto:libcamera-devel-request@lists.libcamera.org?subject=subscribe>","From":"Nicolas Dufresne via libcamera-devel\n\t<libcamera-devel@lists.libcamera.org>","Reply-To":"Nicolas Dufresne <nicolas@ndufresne.ca>","Cc":"Nicolas Dufresne <nicolas.dufresne@collabora.com>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"From: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n\nInstead of editing the registry, use gst_env variable provided by the plugin and\nalready used as part of the devenv shell. This reduces the complexity of the\nC++ test code.\n\nSigned-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>\n---\nNew in V2\n\n test/gstreamer/gstreamer_test.cpp | 17 -----------------\n test/gstreamer/meson.build        |  2 +-\n 2 files changed, 1 insertion(+), 18 deletions(-)","diff":"diff --git a/test/gstreamer/gstreamer_test.cpp b/test/gstreamer/gstreamer_test.cpp\nindex 091f7bf7..e8119b85 100644\n--- a/test/gstreamer/gstreamer_test.cpp\n+++ b/test/gstreamer/gstreamer_test.cpp\n@@ -51,23 +51,6 @@ GstreamerTest::GstreamerTest(unsigned int numStreams)\n \t\treturn;\n \t}\n \n-\t/*\n-\t * Remove the system libcamera plugin, if any, and add the plugin from\n-\t * the build directory.\n-\t */\n-\tGstRegistry *registry = gst_registry_get();\n-\tg_autoptr(GstPlugin) plugin = gst_registry_lookup(registry, \"libgstlibcamera.so\");\n-\tif (plugin)\n-\t\tgst_registry_remove_plugin(registry, plugin);\n-\n-\tstd::string path = libcamera::utils::libcameraBuildPath() + \"src/gstreamer\";\n-\tif (!gst_registry_scan_path(registry, path.c_str())) {\n-\t\tg_printerr(\"Failed to add plugin to registry\\n\");\n-\n-\t\tstatus_ = TestFail;\n-\t\treturn;\n-\t}\n-\n \t/*\n \t * Atleast one camera should be available with numStreams streams,\n \t * otherwise skip the test entirely.\ndiff --git a/test/gstreamer/meson.build b/test/gstreamer/meson.build\nindex a5c003b6..f3ba5a23 100644\n--- a/test/gstreamer/meson.build\n+++ b/test/gstreamer/meson.build\n@@ -17,5 +17,5 @@ foreach test : gstreamer_tests\n                      link_with : test_libraries,\n                      include_directories : test_includes_internal)\n \n-    test(test['name'], exe, suite : 'gstreamer', is_parallel : false)\n+    test(test['name'], exe, suite : 'gstreamer', is_parallel : false, env : gst_env)\n endforeach\n","prefixes":["libcamera-devel","v2","2/2"]}