aboutsummaryrefslogtreecommitdiff
path: root/types_test.cpp
diff options
context:
space:
mode:
authorshaju <shaju@google.com>2022-11-28 20:57:32 -0800
committershaju <shaju@google.com>2022-11-28 20:57:32 -0800
commit56ed67220d59604fdb279f1da642524d0b1bf91c (patch)
tree547d1a420bcafb85949e6f41b692d6d82933ed00 /types_test.cpp
parent763ab7bb17e9c63b238222085e1e69552d978367 (diff)
downloadadb-56ed67220d59604fdb279f1da642524d0b1bf91c.tar.gz
Coverage enhanement for IOVector.
Bug: 260117469 Test: $ ./adb_test --gtest_filter='*IOVector.move_constructor*' Change-Id: Icb443bcc77ac93174bd6ecf0989ef776fdf4b3b0
Diffstat (limited to 'types_test.cpp')
-rw-r--r--types_test.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/types_test.cpp b/types_test.cpp
index 086a35dd..009bcc11 100644
--- a/types_test.cpp
+++ b/types_test.cpp
@@ -47,6 +47,12 @@ TEST(IOVector, empty) {
CHECK_EQ(0ULL, bc.coalesce().size());
}
+TEST(IOVector, move_constructor) {
+ IOVector x;
+ IOVector y(std::move(x));
+ CHECK_EQ(x.coalesce().size(), y.coalesce().size());
+}
+
TEST(IOVector, single_block) {
// A single block.
auto block = create_block('x', 100);