Skip to content

Commit

Permalink
Fix one simple istream test, buffer lifetime.
Browse files Browse the repository at this point in the history
  • Loading branch information
evoskuil committed May 2, 2023
1 parent eab84dd commit 16403d9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/stream/simple/istream.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,8 @@ BOOST_AUTO_TEST_CASE(istream__read__full_buffer__goodbit)

BOOST_AUTO_TEST_CASE(istream__reader__read_8_bytes_big_endian__exected_goodbit)
{
istream_chunk stream{ base16_chunk("010203040506070809") };
const auto chunk = base16_chunk("010203040506070809");
istream_chunk stream{ chunk };
byte_reader<istream_chunk> reader{ stream };
BOOST_REQUIRE_EQUAL(reader.read_8_bytes_big_endian(), 0x0102030405060708_u64);
BOOST_REQUIRE(stream.rdstate() == istream_chunk::goodbit);
Expand Down

0 comments on commit 16403d9

Please sign in to comment.