forked from boostorg/beast
Add test::error to experimental
This commit is contained in:
+10
-10
@@ -51,7 +51,7 @@ public:
|
||||
test::fail_counter fc(n);
|
||||
test::stream ts{ioc_, fc};
|
||||
test_parser<isRequest> p(fc);
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
ts.close_remote();
|
||||
read(ts, b, p, ec);
|
||||
if(! ec)
|
||||
@@ -68,7 +68,7 @@ public:
|
||||
test::stream ts{ioc_, fc,
|
||||
std::string(s + pre, len - pre)};
|
||||
test_parser<isRequest> p(fc);
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
ts.close_remote();
|
||||
read(ts, b, p, ec);
|
||||
if(! ec)
|
||||
@@ -83,7 +83,7 @@ public:
|
||||
test::fail_counter fc(n);
|
||||
test::stream ts{ioc_, fc};
|
||||
test_parser<isRequest> p(fc);
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
ts.close_remote();
|
||||
async_read(ts, b, p, do_yield[ec]);
|
||||
if(! ec)
|
||||
@@ -98,7 +98,7 @@ public:
|
||||
test::fail_counter fc(n);
|
||||
test::stream ts{ioc_, fc};
|
||||
test_parser<isRequest> p(fc);
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
ts.close_remote();
|
||||
async_read_header(ts, b, p, do_yield[ec]);
|
||||
if(! ec)
|
||||
@@ -115,7 +115,7 @@ public:
|
||||
test::stream ts(ioc_, fc,
|
||||
std::string{s + pre, len - pre});
|
||||
test_parser<isRequest> p(fc);
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
ts.close_remote();
|
||||
async_read(ts, b, p, do_yield[ec]);
|
||||
if(! ec)
|
||||
@@ -178,7 +178,7 @@ public:
|
||||
"10\r\n"
|
||||
"****************\r\n"
|
||||
"0\r\n\r\n";
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
flat_static_buffer<10> b;
|
||||
request<string_body> req;
|
||||
read(c, b, req, ec);
|
||||
@@ -286,7 +286,7 @@ public:
|
||||
"\r\n"
|
||||
};
|
||||
request<dynamic_body> m;
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
multi_buffer b;
|
||||
read(ts, b, m, ec);
|
||||
if(! ec)
|
||||
@@ -305,7 +305,7 @@ public:
|
||||
"\r\n"
|
||||
};
|
||||
request<dynamic_body> m;
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
multi_buffer b;
|
||||
async_read(c, b, m, do_yield[ec]);
|
||||
if(! ec)
|
||||
@@ -324,7 +324,7 @@ public:
|
||||
"\r\n"
|
||||
};
|
||||
request_parser<dynamic_body> m;
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
multi_buffer b;
|
||||
async_read_some(c, b, m, do_yield[ec]);
|
||||
if(! ec)
|
||||
@@ -435,7 +435,7 @@ public:
|
||||
for(std::size_t n = 1; n < s.size() - 1; ++n)
|
||||
{
|
||||
Parser p;
|
||||
error_code ec = test::error::fail_error;
|
||||
error_code ec = test::error::test_failure;
|
||||
flat_buffer b;
|
||||
test::stream ts{ioc_};
|
||||
ostream(ts.buffer()) << s;
|
||||
|
||||
Reference in New Issue
Block a user