Skip to content

Commit

Permalink
- extended testcase
Browse files Browse the repository at this point in the history
  • Loading branch information
aschnell committed Jul 8, 2024
1 parent ffda11d commit fd03468
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions stomp/testsuite/read1.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ BOOST_AUTO_TEST_CASE(test1)

BOOST_AUTO_TEST_CASE(test2)
{
// optional content-lenght
// optional content-lenght and body with null character

istringstream s1("HELLO\nkey:value\ncontent-length:5\n\nWORLD" + null);
istringstream s1("HELLO\nkey:value\ncontent-length:5\n\nW" + null + "RLD" + null);
istream s2(s1.rdbuf());

Message msg = read_message(s2);
Expand All @@ -51,7 +51,7 @@ BOOST_AUTO_TEST_CASE(test2)
BOOST_CHECK_EQUAL(msg.headers["key"], "value");
BOOST_CHECK_EQUAL(msg.headers["content-length"], "5");

BOOST_CHECK_EQUAL(msg.body, "WORLD");
BOOST_CHECK_EQUAL(msg.body, "W" + null + "RLD");
}


Expand Down

0 comments on commit fd03468

Please sign in to comment.