summaryrefslogtreecommitdiff
path: root/src/mongo/bson/bson_obj_test.cpp
diff options
context:
space:
mode:
authorJonathan Reams <jbreams@mongodb.com>2019-03-27 12:06:48 -0400
committerJonathan Reams <jbreams@mongodb.com>2019-04-06 12:40:33 -0400
commit83383eb160f904c699b399ac59ccbbf103ad6102 (patch)
treed82abc4d7f7f10181b103461c936682813787e56 /src/mongo/bson/bson_obj_test.cpp
parent652d22504d2990b2322aefc272b489e731edd789 (diff)
downloadmongo-83383eb160f904c699b399ac59ccbbf103ad6102.tar.gz
SERVER-40356 Make ConstDataRange constructable from any byte-like type
Diffstat (limited to 'src/mongo/bson/bson_obj_test.cpp')
-rw-r--r--src/mongo/bson/bson_obj_test.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mongo/bson/bson_obj_test.cpp b/src/mongo/bson/bson_obj_test.cpp
index a061d67f67b..e966af9d559 100644
--- a/src/mongo/bson/bson_obj_test.cpp
+++ b/src/mongo/bson/bson_obj_test.cpp
@@ -689,7 +689,7 @@ TEST(BSONObj, sizeChecks) {
auto generateBuffer = [](std::int32_t size) {
std::vector<char> buffer(size);
DataRange bufferRange(&buffer.front(), &buffer.back());
- ASSERT_OK(bufferRange.write(LittleEndian<int32_t>(size)));
+ ASSERT_OK(bufferRange.writeNoThrow(LittleEndian<int32_t>(size)));
return buffer;
};