forked from boostorg/beast
Tidy up tests and docs:
* Add handler_ptr test and increase coverage * Add test for prepare_buffer * Move is_call_possible tests to a .cpp file * Tidy up docs and declarations
This commit is contained in:
@@ -16,15 +16,17 @@ namespace beast {
|
||||
class bind_handler_test : public unit_test::suite
|
||||
{
|
||||
public:
|
||||
static void foo (int)
|
||||
void
|
||||
callback(int v)
|
||||
{
|
||||
BEAST_EXPECT(v == 42);
|
||||
}
|
||||
|
||||
void run()
|
||||
{
|
||||
auto f (bind_handler (
|
||||
std::bind (&foo, std::placeholders::_1),
|
||||
42));
|
||||
auto f = bind_handler(std::bind(
|
||||
&bind_handler_test::callback, this,
|
||||
std::placeholders::_1), 42);
|
||||
f();
|
||||
pass();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user