Skip to content

Commit 12d8e35

Browse files
committed
adjust test setup
1 parent fc4c56e commit 12d8e35

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

google/cloud/bigtable/tests/data_integration_test.cc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -931,11 +931,14 @@ TEST_P(DataIntegrationTest, QueryWithNulls) {
931931
std::string const row_key3 = "query-with-nulls-row-3";
932932
std::string const family = kFamily4;
933933
std::string const column1 = "c1";
934+
std::string const column2 = "c2";
934935
std::string const value1 = "v1";
935936
std::string const value3 = "v3";
936937

938+
// Create row_key2 with no value for column 1.
937939
std::vector<Cell> created = {
938940
{row_key1, family, column1, 0, value1},
941+
{row_key2, family, column2, 0, ""},
939942
{row_key3, family, column1, 0, value3},
940943
};
941944
BulkApply(table, created);
@@ -963,11 +966,12 @@ TEST_P(DataIntegrationTest, QueryWithNulls) {
963966
ASSERT_STATUS_OK(row);
964967
actual_rows.push_back(*std::move(row));
965968
}
966-
EXPECT_EQ(actual_rows.size(), 2);
969+
EXPECT_EQ(actual_rows.size(), 3);
967970
EXPECT_THAT(
968971
actual_rows,
969972
UnorderedElementsAre(
970973
std::make_tuple(row_key1, absl::optional<std::string>(value1)),
974+
std::make_tuple(row_key2, absl::optional<std::string>(absl::nullopt)),
971975
std::make_tuple(row_key3, absl::optional<std::string>(value3))));
972976
}
973977

0 commit comments

Comments
 (0)