Prepare for one shot array reading
With the patch changing the behavior for arrays of numbers, we want
these tests to continue testing the iteration array read paths. In the
next commit, std::vector<uint8_t> will no longer be using iteration
paths, so change the unit test to use strings instead. Next commit will
add back equivalent coverage.
Change-Id: I7484ac54b6f964596b5e914734999e6441b5e9c7
Signed-off-by: Ed Tanous <ed@tanous.net>
diff --git a/test/message/append.cpp b/test/message/append.cpp
index 20ca441..e753b01 100644
--- a/test/message/append.cpp
+++ b/test/message/append.cpp
@@ -285,14 +285,14 @@
TEST_F(AppendTest, Vector)
{
- const std::vector<int> v{1, 2, 3, 4};
+ const std::vector<std::string> v{"a", "b", "c", "d"};
{
testing::InSequence seq;
- expect_open_container(SD_BUS_TYPE_ARRAY, "i");
+ expect_open_container(SD_BUS_TYPE_ARRAY, "s");
for (const auto& i : v)
{
- expect_basic<int>(SD_BUS_TYPE_INT32, i);
+ expect_basic_string(SD_BUS_TYPE_STRING, i.c_str());
}
expect_close_container();
}