{"id":11410,"url":"https://patchwork.libcamera.org/api/1.1/patches/11410/?format=json","web_url":"https://patchwork.libcamera.org/patch/11410/","project":{"id":1,"url":"https://patchwork.libcamera.org/api/1.1/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":"<20210301065226.11095-2-paul.elder@ideasonboard.com>","date":"2021-03-01T06:52:24","name":"[libcamera-devel,v9,1/3] tests: Add IPADataSerializer test","commit_ref":null,"pull_url":null,"state":"accepted","archived":false,"hash":"a6afd6bbff0c939c2d93760aac1c883e9238537c","submitter":{"id":17,"url":"https://patchwork.libcamera.org/api/1.1/people/17/?format=json","name":"Paul Elder","email":"paul.elder@ideasonboard.com"},"delegate":null,"mbox":"https://patchwork.libcamera.org/patch/11410/mbox/","series":[{"id":1733,"url":"https://patchwork.libcamera.org/api/1.1/series/1733/?format=json","web_url":"https://patchwork.libcamera.org/project/libcamera/list/?series=1733","date":"2021-03-01T06:52:23","name":"IPA isolation tests","version":9,"mbox":"https://patchwork.libcamera.org/series/1733/mbox/"}],"comments":"https://patchwork.libcamera.org/api/patches/11410/comments/","check":"pending","checks":"https://patchwork.libcamera.org/api/patches/11410/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 8DA95BD808\n\tfor <parsemail@patchwork.libcamera.org>;\n\tMon,  1 Mar 2021 06:52:39 +0000 (UTC)","from lancelot.ideasonboard.com (localhost [IPv6:::1])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTP id 553D268A84;\n\tMon,  1 Mar 2021 07:52:39 +0100 (CET)","from perceval.ideasonboard.com (perceval.ideasonboard.com\n\t[IPv6:2001:4b98:dc2:55:216:3eff:fef7:d647])\n\tby lancelot.ideasonboard.com (Postfix) with ESMTPS id 18A0F68A84\n\tfor <libcamera-devel@lists.libcamera.org>;\n\tMon,  1 Mar 2021 07:52:37 +0100 (CET)","from pyrite.rasen.tech (unknown\n\t[IPv6:2400:4051:61:600:2c71:1b79:d06d:5032])\n\tby perceval.ideasonboard.com (Postfix) with ESMTPSA id 8303D332;\n\tMon,  1 Mar 2021 07:52:35 +0100 (CET)"],"Authentication-Results":"lancelot.ideasonboard.com;\n\tdkim=fail reason=\"signature verification failed\" (1024-bit key;\n\tunprotected) header.d=ideasonboard.com header.i=@ideasonboard.com\n\theader.b=\"D44+JZlQ\"; dkim-atps=neutral","DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com;\n\ts=mail; t=1614581556;\n\tbh=O71AxfC6sgufsJo1h1G9W2x6e+kVv4UBydqtlB1Z8BU=;\n\th=From:To:Cc:Subject:Date:In-Reply-To:References:From;\n\tb=D44+JZlQiosYpxs82xuJ/9+Lru49aeL14+ifXJtkqZUviRX/13GqXgd/hHxbAXwF/\n\tMaLKVFOnJXro7IT07xOpaO5g2wrjMLAEYSfXsiAqgb6BUbkC27eaDJfLZn5XKrI2e6\n\trBj306yxi/vLSEGU9oW5c7wk+6sEn1U7C3hwqCO4=","From":"Paul Elder <paul.elder@ideasonboard.com>","To":"libcamera-devel@lists.libcamera.org","Date":"Mon,  1 Mar 2021 15:52:24 +0900","Message-Id":"<20210301065226.11095-2-paul.elder@ideasonboard.com>","X-Mailer":"git-send-email 2.27.0","In-Reply-To":"<20210301065226.11095-1-paul.elder@ideasonboard.com>","References":"<20210301065226.11095-1-paul.elder@ideasonboard.com>","MIME-Version":"1.0","Subject":"[libcamera-devel] [PATCH v9 1/3] tests: Add IPADataSerializer test","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>","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Errors-To":"libcamera-devel-bounces@lists.libcamera.org","Sender":"\"libcamera-devel\" <libcamera-devel-bounces@lists.libcamera.org>"},"content":"Test the IPADataSerializer for controls, vectors, maps, and PODs of\nbuilt-in types.\n\nSigned-off-by: Paul Elder <paul.elder@ideasonboard.com>\n\n---\nChanges in v9:\n- convert C-style macros to C++ templates\n- simplify (aka remove) the custom map/vector comparators\n- remove dependency on the raspberrypi header, and create our own\n  testing ControlInfoMap\n- reduce the size of the string for testing serializing big objects\n\nNo change in v8\n\nChanges in v7:\n- remove printing values of vectors/maps\n- simplify map and vector equality check\n- return immediately on the first failure\n\nChanges in v6:\n- no longer need to initialize rpi ControlInfoMap\n- no longer need to pass ControlInfoMap to the ControlList serializer\n\nChanges in v5:\n- use ControlInfoMap serializer instead of const ControlInfoMap\n  serializer\n\nChanges in v4:\n- use RPi::controls instead RPi::Controls\n\nChanges in v3:\n- use re-namespaced RPi::Controls\n\nNew in v2\n---\n .../ipa_data_serializer_test.cpp              | 440 ++++++++++++++++++\n test/serialization/meson.build                |   1 +\n 2 files changed, 441 insertions(+)\n create mode 100644 test/serialization/ipa_data_serializer_test.cpp","diff":"diff --git a/test/serialization/ipa_data_serializer_test.cpp b/test/serialization/ipa_data_serializer_test.cpp\nnew file mode 100644\nindex 00000000..5e9e2bea\n--- /dev/null\n+++ b/test/serialization/ipa_data_serializer_test.cpp\n@@ -0,0 +1,440 @@\n+/* SPDX-License-Identifier: GPL-2.0-or-later */\n+/*\n+ * Copyright (C) 2020, Google Inc.\n+ *\n+ * ipa_data_serializer_test.cpp - Test serializing/deserializing with IPADataSerializer\n+ */\n+\n+#include <algorithm>\n+#include <cxxabi.h>\n+#include <fcntl.h>\n+#include <iostream>\n+#include <limits>\n+#include <stdlib.h>\n+#include <string.h>\n+#include <sys/stat.h>\n+#include <sys/types.h>\n+#include <tuple>\n+#include <unistd.h>\n+#include <vector>\n+\n+#include \"libcamera/internal/device_enumerator.h\"\n+#include \"libcamera/internal/ipa_data_serializer.h\"\n+#include \"libcamera/internal/ipa_manager.h\"\n+#include \"libcamera/internal/ipa_module.h\"\n+#include \"libcamera/internal/pipeline_handler.h\"\n+#include \"libcamera/internal/thread.h\"\n+#include \"libcamera/internal/timer.h\"\n+\n+#include \"serialization_test.h\"\n+#include \"test.h\"\n+\n+using namespace std;\n+using namespace libcamera;\n+\n+static const ControlInfoMap Controls = {\n+\t{ &controls::AeEnable, ControlInfo(false, true) },\n+\t{ &controls::ExposureTime, ControlInfo(0, 999999) },\n+\t{ &controls::AnalogueGain, ControlInfo(1.0f, 32.0f) },\n+\t{ &controls::ColourGains, ControlInfo(0.0f, 32.0f) },\n+\t{ &controls::Brightness, ControlInfo(-1.0f, 1.0f) },\n+};\n+\n+namespace libcamera {\n+\n+static bool operator==(const ControlInfoMap &lhs, const ControlInfoMap &rhs)\n+{\n+\treturn SerializationTest::equals(lhs, rhs);\n+}\n+\n+} /* namespace libcamera */\n+\n+template<typename T>\n+int testPodSerdes(T in)\n+{\n+\tstd::vector<uint8_t> buf;\n+\tstd::vector<int32_t> fds;\n+\n+\tstd::tie(buf, fds) = IPADataSerializer<T>::serialize(in);\n+\tT out = IPADataSerializer<T>::deserialize(buf, fds);\n+\tif (in == out)\n+\t\treturn TestPass;\n+\n+\tchar *name = abi::__cxa_demangle(typeid(T).name(), nullptr,\n+\t\t\t\t\t nullptr, nullptr);\n+\tcerr << \"Deserialized \" << name << \" doesn't match original\" << endl;\n+\tfree(name);\n+\treturn TestFail;\n+}\n+\n+template<typename T>\n+int testVectorSerdes(const std::vector<T> &in,\n+\t\t     ControlSerializer *cs = nullptr)\n+{\n+\tstd::vector<uint8_t> buf;\n+\tstd::vector<int32_t> fds;\n+\n+\tstd::tie(buf, fds) = IPADataSerializer<std::vector<T>>::serialize(in, cs);\n+\tstd::vector<T> out = IPADataSerializer<std::vector<T>>::deserialize(buf, fds, cs);\n+\tif (in == out)\n+\t\treturn TestPass;\n+\n+\tchar *name = abi::__cxa_demangle(typeid(T).name(), nullptr,\n+\t\t\t\t\t nullptr, nullptr);\n+\tcerr << \"Deserialized std::vector<\" << name\n+\t     << \"> doesn't match original\" << endl;\n+\tfree(name);\n+\treturn TestFail;\n+}\n+\n+template<typename K, typename V>\n+int testMapSerdes(const std::map<K, V> &in,\n+\t\t  ControlSerializer *cs = nullptr)\n+{\n+\tstd::vector<uint8_t> buf;\n+\tstd::vector<int32_t> fds;\n+\n+\tstd::tie(buf, fds) = IPADataSerializer<std::map<K, V>>::serialize(in, cs);\n+\tstd::map<K, V> out = IPADataSerializer<std::map<K, V>>::deserialize(buf, fds, cs);\n+\tif (in == out)\n+\t\treturn TestPass;\n+\n+\tchar *nameK = abi::__cxa_demangle(typeid(K).name(), nullptr,\n+\t\t\t\t\t  nullptr, nullptr);\n+\tchar *nameV = abi::__cxa_demangle(typeid(V).name(), nullptr,\n+\t\t\t\t\t  nullptr, nullptr);\n+\tcerr << \"Deserialized std::map<\" << nameK << \", \" << nameV\n+\t     << \"> doesn't match original\" << endl;\n+\tfree(nameK);\n+\tfree(nameV);\n+\treturn TestFail;\n+}\n+\n+class IPADataSerializerTest : public CameraTest, public Test\n+{\n+public:\n+\tIPADataSerializerTest()\n+\t\t: CameraTest(\"platform/vimc.0 Sensor B\")\n+\t{\n+\t}\n+\n+protected:\n+\tint init() override\n+\t{\n+\t\treturn status_;\n+\t}\n+\n+\tint run() override\n+\t{\n+\t\tint ret;\n+\n+\t\tret = testControls();\n+\t\tif (ret != TestPass)\n+\t\t\treturn ret;\n+\n+\t\tret = testVector();\n+\t\tif (ret != TestPass)\n+\t\t\treturn ret;\n+\n+\t\tret = testMap();\n+\t\tif (ret != TestPass)\n+\t\t\treturn ret;\n+\n+\t\tret = testPod();\n+\t\tif (ret != TestPass)\n+\t\t\treturn ret;\n+\n+\t\treturn TestPass;\n+\t}\n+\n+private:\n+\tControlList generateControlList(const ControlInfoMap &infoMap)\n+\t{\n+\t\t/* Create a control list with three controls. */\n+\t\tControlList list(infoMap);\n+\n+\t\tlist.set(controls::Brightness, 0.5f);\n+\t\tlist.set(controls::Contrast, 1.2f);\n+\t\tlist.set(controls::Saturation, 0.2f);\n+\n+\t\treturn list;\n+\t}\n+\n+\tint testControls()\n+\t{\n+\t\tControlSerializer cs;\n+\n+\t\tconst ControlInfoMap &infoMap = camera_->controls();\n+\t\tControlList list = generateControlList(infoMap);\n+\n+\t\tstd::vector<uint8_t> infoMapBuf;\n+\t\tstd::tie(infoMapBuf, std::ignore) =\n+\t\t\tIPADataSerializer<ControlInfoMap>::serialize(infoMap, &cs);\n+\n+\t\tstd::vector<uint8_t> listBuf;\n+\t\tstd::tie(listBuf, std::ignore) =\n+\t\t\tIPADataSerializer<ControlList>::serialize(list, &cs);\n+\n+\t\tconst ControlInfoMap infoMapOut =\n+\t\t\tIPADataSerializer<ControlInfoMap>::deserialize(infoMapBuf, &cs);\n+\n+\t\tControlList listOut = IPADataSerializer<ControlList>::deserialize(listBuf, &cs);\n+\n+\t\tif (!SerializationTest::equals(infoMap, infoMapOut)) {\n+\t\t\tcerr << \"Deserialized map doesn't match original\" << endl;\n+\t\t\treturn TestFail;\n+\t\t}\n+\n+\t\tif (!SerializationTest::equals(list, listOut)) {\n+\t\t\tcerr << \"Deserialized list doesn't match original\" << endl;\n+\t\t\treturn TestFail;\n+\t\t}\n+\n+\t\treturn TestPass;\n+\t}\n+\n+\tint testVector()\n+\t{\n+\t\tControlSerializer cs;\n+\n+\t\t/*\n+\t\t * We don't test FileDescriptor serdes because it dup()s, so we\n+\t\t * can't check for equality.\n+\t\t */\n+\t\tstd::vector<uint8_t>  vecUint8  = { 1, 2, 3, 4, 5, 6 };\n+\t\tstd::vector<uint16_t> vecUint16 = { 1, 2, 3, 4, 5, 6 };\n+\t\tstd::vector<uint32_t> vecUint32 = { 1, 2, 3, 4, 5, 6 };\n+\t\tstd::vector<uint64_t> vecUint64 = { 1, 2, 3, 4, 5, 6 };\n+\t\tstd::vector<int8_t>   vecInt8   = { 1, 2, 3, -4, 5, -6 };\n+\t\tstd::vector<int16_t>  vecInt16  = { 1, 2, 3, -4, 5, -6 };\n+\t\tstd::vector<int32_t>  vecInt32  = { 1, 2, 3, -4, 5, -6 };\n+\t\tstd::vector<int64_t>  vecInt64  = { 1, 2, 3, -4, 5, -6 };\n+\t\tstd::vector<float>    vecFloat  = { 1.1, 2.2, 3.3, -4.4, 5.5, -6.6 };\n+\t\tstd::vector<double>   vecDouble = { 1.1, 2.2, 3.3, -4.4, 5.5, -6.6 };\n+\t\tstd::vector<bool>     vecBool   = { true, true, false, false, true, false };\n+\t\tstd::vector<string>   vecString = { \"foo\", \"bar\", \"baz\" };\n+\t\tstd::vector<ControlInfoMap> vecControlInfoMap = {\n+\t\t\tcamera_->controls(),\n+\t\t\tControls,\n+\t\t};\n+\n+\t\tstd::vector<uint8_t> buf;\n+\t\tstd::vector<int32_t> fds;\n+\n+\t\tif (testVectorSerdes(vecUint8) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecUint16) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecUint32) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecUint64) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecInt8) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecInt16) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecInt32) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecInt64) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecFloat) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecDouble) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecBool) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecString) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testVectorSerdes(vecControlInfoMap, &cs) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\treturn TestPass;\n+\t}\n+\n+\tint testMap()\n+\t{\n+\t\tControlSerializer cs;\n+\n+\t\t/*\n+\t\t * Realistically, only string and integral keys.\n+\t\t * Test simple, complex, and nested compound value.\n+\t\t */\n+\t\tstd::map<uint64_t, string> mapUintStr =\n+\t\t\t{ { 101, \"foo\" }, { 102, \"bar\" }, { 103, \"baz\" } };\n+\t\tstd::map<int64_t, string> mapIntStr =\n+\t\t\t{ { 101, \"foo\" }, { -102, \"bar\" }, { -103, \"baz\" } };\n+\t\tstd::map<string, string> mapStrStr =\n+\t\t\t{ { \"a\", \"foo\" }, { \"b\", \"bar\" }, { \"c\", \"baz\" } };\n+\t\tstd::map<uint64_t, ControlInfoMap> mapUintCIM =\n+\t\t\t{ { 201, camera_->controls() }, { 202, Controls } };\n+\t\tstd::map<int64_t, ControlInfoMap> mapIntCIM =\n+\t\t\t{ { 201, camera_->controls() }, { -202, Controls } };\n+\t\tstd::map<string, ControlInfoMap> mapStrCIM =\n+\t\t\t{ { \"a\", camera_->controls() }, { \"b\", Controls } };\n+\t\tstd::map<uint64_t, vector<uint8_t>> mapUintBVec =\n+\t\t\t{ { 301, { 1, 2, 3 } }, { 302, { 4, 5, 6 } }, { 303, { 7, 8, 9 } } };\n+\t\tstd::map<int64_t, vector<uint8_t>> mapIntBVec =\n+\t\t\t{ { 301, { 1, 2, 3 } }, { -302, { 4, 5, 6} }, { -303, { 7, 8, 9 } } };\n+\t\tstd::map<string, vector<uint8_t>> mapStrBVec =\n+\t\t\t{ { \"a\", { 1, 2, 3 } }, { \"b\", { 4, 5, 6 } }, { \"c\", { 7, 8, 9 } } };\n+\n+\t\tstd::vector<uint8_t> buf;\n+\t\tstd::vector<int32_t> fds;\n+\n+\t\tif (testMapSerdes(mapUintStr) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapIntStr) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapStrStr) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapUintCIM, &cs) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapIntCIM,  &cs) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapStrCIM,  &cs) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapUintBVec) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapIntBVec) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testMapSerdes(mapStrBVec) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\treturn TestPass;\n+\t}\n+\n+\tint testPod()\n+\t{\n+\t\tuint32_t u32min = numeric_limits<uint32_t>::min();\n+\t\tuint32_t u32max = numeric_limits<uint32_t>::max();\n+\t\tuint32_t u32one = 1;\n+\t\tint32_t  i32min = numeric_limits<int32_t>::min();\n+\t\tint32_t  i32max = numeric_limits<int32_t>::max();\n+\t\tint32_t  i32one = 1;\n+\n+\t\tuint64_t u64min = numeric_limits<uint64_t>::min();\n+\t\tuint64_t u64max = numeric_limits<uint64_t>::max();\n+\t\tuint64_t u64one = 1;\n+\t\tint64_t  i64min = numeric_limits<int64_t>::min();\n+\t\tint64_t  i64max = numeric_limits<int64_t>::max();\n+\t\tint64_t  i64one = 1;\n+\n+\t\tfloat  flow = numeric_limits<float>::lowest();\n+\t\tfloat  fmin = numeric_limits<float>::min();\n+\t\tfloat  fmax = numeric_limits<float>::max();\n+\t\tfloat  falmostOne = 1 + 1.0e-37;\n+\t\tdouble dlow = numeric_limits<double>::lowest();\n+\t\tdouble dmin = numeric_limits<double>::min();\n+\t\tdouble dmax = numeric_limits<double>::max();\n+\t\tdouble dalmostOne = 1 + 1.0e-307;\n+\n+\t\tbool t = true;\n+\t\tbool f = false;\n+\n+\t\tstringstream ss;\n+\t\tfor (unsigned int i = 0; i < (1 << 11); i++)\n+\t\t\tss << \"0123456789\";\n+\n+\t\tstring strLong = ss.str();\n+\t\tstring strEmpty = \"\";\n+\n+\t\tstd::vector<uint8_t> buf;\n+\t\tstd::vector<int32_t> fds;\n+\n+\t\tif (testPodSerdes(u32min) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(u32max) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(u32one) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i32min) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i32max) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i32one) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(u64min) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(u64max) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(u64one) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i64min) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i64max) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(i64one) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(flow) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(fmin) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(fmax) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(falmostOne) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(dlow) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(dmin) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(dmax) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(dalmostOne) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(t) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(f) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(strLong) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\tif (testPodSerdes(strEmpty) != TestPass)\n+\t\t\treturn TestFail;\n+\n+\t\treturn TestPass;\n+\t}\n+};\n+\n+TEST_REGISTER(IPADataSerializerTest)\ndiff --git a/test/serialization/meson.build b/test/serialization/meson.build\nindex 6fc54f6b..a4636337 100644\n--- a/test/serialization/meson.build\n+++ b/test/serialization/meson.build\n@@ -2,6 +2,7 @@\n \n serialization_tests = [\n     ['control_serialization',     'control_serialization.cpp'],\n+    ['ipa_data_serializer_test',  'ipa_data_serializer_test.cpp'],\n ]\n \n foreach t : serialization_tests\n","prefixes":["libcamera-devel","v9","1/3"]}