1//
2// Copyright (c) 2016-2019 Vinnie Falco (vinnie dot falco at gmail dot com)
3//
4// Distributed under the Boost Software License, Version 1.0. (See accompanying
5// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6//
7// Official repository: https://github.com/boostorg/beast
8//
9
10// Test that header file is self-contained.
11#include <boost/beast/core/tcp_stream.hpp>
12
13#include <boost/beast/_experimental/unit_test/suite.hpp>
14
15namespace boost {
16namespace beast {
17
18// compile test for other exec
19template class basic_stream<
20 net::ip::tcp,
21 net::io_context::executor_type,
22 unlimited_rate_policy> ;
23
24class tcp_stream_test
25 : public beast::unit_test::suite
26{
27public:
28 using tcp = net::ip::tcp;
29
30 void
31 testStream()
32 {
33 net::io_context ioc;
34 {
35 tcp::socket s(ioc);
36 tcp_stream s1(std::move(s));
37 }
38 }
39
40 void
41 run()
42 {
43 testStream();
44 pass();
45 }
46};
47
48BEAST_DEFINE_TESTSUITE(beast,core,tcp_stream);
49
50} // beast
51} // boost
52

source code of boost/libs/beast/test/beast/core/tcp_stream.cpp