{"id":24230,"url":"https://patchwork.libcamera.org/api/patches/24230/?format=json","web_url":"https://patchwork.libcamera.org/patch/24230/","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":"<20250825114409.569050-1-paul.elder@ideasonboard.com>","date":"2025-08-25T11:44:09","name":"test: utils: Add endlines","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"4dfa75a9e8c05c51e1a65e72da15739c1626fe3d","submitter":{"id":17,"url":"https://patchwork.libcamera.org/api/people/17/?format=json","name":"Paul Elder","email":"paul.elder@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/24230/mbox/","series":[{"id":5402,"url":"https://patchwork.libcamera.org/api/series/5402/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=5402","date":"2025-08-25T11:44:09","name":"test: utils: Add endlines","version":1,"mbox":"https://patchwork.libcamera.org/series/5402/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/24230/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/24230/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 3F2F5BEFBE\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon, 25 Aug 2025 11:44:24 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id DD308692ED;\n\tMon, 25 Aug 2025 13:44:23 +0200 (CEST)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[213.167.242.64])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 39DC1692CA\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon, 25 Aug 2025 13:44:22 +0200 (CEST)","from neptunite.infra.iob (unknown\n\t[IPv6:2404:7a81:160:2100:39d7:37aa:64a2:5533])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 149062285;\n\tMon, 25 Aug 2025 13:43:18 +0200 (CEST)"],"Authentication-Results":"lancelot.ideasonboard.com; dkim=pass (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"cDHZycwl\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1756122200;\n\tbh=2jNgxbH/TJrbZsNEpU2wRU2f1EEn/Vw9JLm6+MO46fE=;\n\th=From:To:Cc:Subject:Date:From;\n\tb=cDHZycwlrqVeBpiG7XS3W618RRTrX/vzWbDHXE9XgunkTXOEZrP2rENErNjTfBQg1\n\tygz8vgfvTfm2KYFvj/M6fX8jMrLZxgtwJvCj0sXYLPAhrPBBVY5af9EgxfoHR4M51M\n\tmqBECjx7TCkXpP6XCnUGtEjUKBquNBW6EFV+vND8=","From":"Paul Elder <paul.elder@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Cc":"Paul Elder <paul.elder@ideasonboard.com>","Subject":"[PATCH] test: utils: Add endlines","Date":"Mon, 25 Aug 2025 20:44:09 +0900","Message-ID":"<20250825114409.569050-1-paul.elder@ideasonboard.com>","X-Mailer":"git-send-email 2.47.2","MIME-Version":"1.0","Content-Transfer-Encoding":"8bit","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>","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Most of the error messages from the utils test had no endlines. Add them\nso that the output is nicer.\n\nSigned-off-by: Paul Elder <paul.elder@ideasonboard.com>\n---\n test/utils.cpp | 18 +++++++++---------\n 1 file changed, 9 insertions(+), 9 deletions(-)","diff":"diff --git a/test/utils.cpp b/test/utils.cpp\nindex 195fddc97d97..ae5b01746722 100644\n--- a/test/utils.cpp\n+++ b/test/utils.cpp\n@@ -85,7 +85,7 @@ protected:\n \t\t\tif (index != i || value != i + 1) {\n \t\t\t\tcerr << \"utils::enumerate(<vector>) test failed: i=\" << i\n \t\t\t\t     << \", index=\" << index << \", value=\" << value\n-\t\t\t\t     << std::endl;\n+\t\t\t\t     << endl;\n \t\t\t\treturn TestFail;\n \t\t\t}\n \n@@ -106,7 +106,7 @@ protected:\n \t\t\tif (index != i || value != i) {\n \t\t\t\tcerr << \"utils::enumerate(<span>) test failed: i=\" << i\n \t\t\t\t     << \", index=\" << index << \", value=\" << value\n-\t\t\t\t     << std::endl;\n+\t\t\t\t     << endl;\n \t\t\t\treturn TestFail;\n \t\t\t}\n \n@@ -120,7 +120,7 @@ protected:\n \t\t\tif (index != i || value != i * 2) {\n \t\t\t\tcerr << \"utils::enumerate(<array>) test failed: i=\" << i\n \t\t\t\t     << \", index=\" << index << \", value=\" << value\n-\t\t\t\t     << std::endl;\n+\t\t\t\t     << endl;\n \t\t\t\treturn TestFail;\n \t\t\t}\n \n@@ -138,32 +138,32 @@ protected:\n \n \t\texposure = 25ms + 25ms;\n \t\tif (exposure.get<std::micro>() != 50000.0) {\n-\t\t\tcerr << \"utils::Duration failed to return microsecond count\";\n+\t\t\tcerr << \"utils::Duration failed to return microsecond count\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n \t\texposure = 1.0s / 4;\n \t\tif (exposure != 250ms) {\n-\t\t\tcerr << \"utils::Duration failed scalar divide test\";\n+\t\t\tcerr << \"utils::Duration failed scalar divide test\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n \t\texposure = 5000.5us;\n \t\tif (!exposure) {\n-\t\t\tcerr << \"utils::Duration failed boolean test\";\n+\t\t\tcerr << \"utils::Duration failed boolean test\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n \t\tos << exposure;\n \t\tif (os.str() != \"5000.50us\") {\n-\t\t\tcerr << \"utils::Duration operator << failed\";\n+\t\t\tcerr << \"utils::Duration operator << failed\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n \t\texposure = 100ms;\n \t\tratio = exposure / 25ms;\n \t\tif (ratio != 4.0) {\n-\t\t\tcerr << \"utils::Duration failed ratio test\";\n+\t\t\tcerr << \"utils::Duration failed ratio test\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n@@ -219,7 +219,7 @@ protected:\n \t\tstd::string s = os.str();\n \t\tif (s != ref) {\n \t\t\tcerr << \"utils::hex() test failed, expected '\" << ref\n-\t\t\t     << \"', got '\" << s << \"'\";\n+\t\t\t     << \"', got '\" << s << \"'\" << endl;\n \t\t\treturn TestFail;\n \t\t}\n \n","prefixes":[]}