forked from boostorg/beast
Parser concept, fixes:
A new concept Parser is introduced with routines to read from a stream into the parser. This solves a problem with the old read interface where messages must be default constructible and move assignable. Parser fixes: * Fix detect invalid reason-phrase octets * Fix write_eof to set the 'complete' state on success * Fix consider parse complete if eof received on empty body WebSocket: * Increase coverage
This commit is contained in:
1 parent
8921da91b8
commit
2a8de0fd6b
28 files changed
+1536
-701
No files matched your search
@@ -32,7 +32,7 @@ operator==(frame_header const& lhs, frame_header const& rhs)
|
||||
class frame_test : public beast::unit_test::suite
|
||||
{
|
||||
public:
|
||||
void testValidOpcode()
|
||||
void testCloseCodes()
|
||||
{
|
||||
expect(! is_valid(0));
|
||||
expect(! is_valid(1));
|
||||
@@ -43,6 +43,8 @@ public:
|
||||
expect(! is_valid(1016));
|
||||
expect(! is_valid(2000));
|
||||
expect(! is_valid(2999));
|
||||
expect(is_valid(1000));
|
||||
expect(is_valid(1002));
|
||||
expect(is_valid(3000));
|
||||
expect(is_valid(4000));
|
||||
expect(is_valid(5000));
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
void run() override
|
||||
{
|
||||
testValidOpcode();
|
||||
testCloseCodes();
|
||||
testFrameHeader();
|
||||
testBadFrameHeaders();
|
||||
pass();
|
||||
|
||||
Reference in new issue
Block a user