src/third_party/protobuf/src/google/protobuf/io/zero_copy_stream_unittest.cc
TEST_F(IoTest, LargeOutput) {
  std::string str;
  StringOutputStream output(&str);
  void* unused_data;
  int size;
  // Repeatedly calling Next should eventually grow the buffer to kint32max.
  do {
    EXPECT_TRUE(output.Next(&unused_data, &size));
  } while (str.size() < std::numeric_limits<int>::max());
  // Further increases should be possible.
  output.Next(&unused_data, &size);
  EXPECT_GT(size, 0);
}
// Verifies that outputs up to kint32max can be created.
Verifies that outputs up to kint32max can be created.
Verifies that outputs up to kint32max can be created .
TEST_F(IoTest, LargeOutput) {
  std::string str;
  StringOutputStream output(&str);
  void* unused_data;
  int size;
  do {
    EXPECT_TRUE(output.Next(&unused_data, &size));
  } while (str.size() < std::numeric_limits<int>::max());
  output.Next(&unused_data, &size);
  EXPECT_GT(size, 0);
}
TEST_F ( IoTest , LargeOutput ) { std :: string str ; StringOutputStream output ( & str ) ; void * unused_data ; int size ; do { EXPECT_TRUE ( output . Next ( & unused_data , & size ) ) ; } while ( str . size ( ) < std :: numeric_limits < int > :: max ( ) ) ; output . Next ( & unused_data , & size ) ; EXPECT_GT ( size , 0 ) ; }
Verifies that outputs up to kint32max can be created.
Verifies that outputs up to kint32max can be created .
// Repeatedly calling Next should eventually grow the buffer to kint32max. // Further increases should be possible.