diff --git a/example/hello_world_over_tls.cpp b/example/hello_world_over_tls.cpp index 048f664..b97e810 100644 --- a/example/hello_world_over_tls.cpp +++ b/example/hello_world_over_tls.cpp @@ -29,7 +29,7 @@ struct tls_handshake_type> { template void assign_tls_sni( const authority_path& ap, - boost::asio::ssl::context& ctx, + boost::asio::ssl::context& /* ctx */, boost::asio::ssl::stream& stream ) { SSL_set_tlsext_host_name(stream.native_handle(), ap.host.c_str()); diff --git a/example/publisher.cpp b/example/publisher.cpp index a9a5d83..1461bf1 100644 --- a/example/publisher.cpp +++ b/example/publisher.cpp @@ -6,8 +6,10 @@ // //[publisher +#include #include #include +#include #include #include diff --git a/example/timeout_with_awaitable_operators.cpp b/example/timeout_with_awaitable_operators.cpp index 28f68e3..abf5009 100644 --- a/example/timeout_with_awaitable_operators.cpp +++ b/example/timeout_with_awaitable_operators.cpp @@ -6,6 +6,7 @@ // //[timeout_with_awaitable_operators +#include #include #include diff --git a/example/timeout_with_parallel_group.cpp b/example/timeout_with_parallel_group.cpp index eb7dae8..191ffac 100644 --- a/example/timeout_with_parallel_group.cpp +++ b/example/timeout_with_parallel_group.cpp @@ -6,10 +6,15 @@ // //[timeout_with_parallel_group +#include +#include #include +#include +#include #include #include +#include #include #include #include diff --git a/include/async_mqtt5/detail/any_authenticator.hpp b/include/async_mqtt5/detail/any_authenticator.hpp index 7514686..3e7b4f9 100644 --- a/include/async_mqtt5/detail/any_authenticator.hpp +++ b/include/async_mqtt5/detail/any_authenticator.hpp @@ -8,8 +8,14 @@ #ifndef ASYNC_MQTT5_ANY_AUTHENTICATOR #define ASYNC_MQTT5_ANY_AUTHENTICATOR +#include +#include +#include +#include + #include #include +#include #include #include @@ -22,7 +28,7 @@ namespace asio = boost::asio; using error_code = boost::system::error_code; using auth_handler_type = asio::any_completion_handler< - void (error_code ec, std::string auth_data) + void (error_code, std::string) >; template diff --git a/include/async_mqtt5/detail/async_mutex.hpp b/include/async_mqtt5/detail/async_mutex.hpp index d2a542b..568b849 100644 --- a/include/async_mqtt5/detail/async_mutex.hpp +++ b/include/async_mqtt5/detail/async_mutex.hpp @@ -8,13 +8,19 @@ #ifndef ASYNC_MQTT5_ASYNC_MUTEX_HPP #define ASYNC_MQTT5_ASYNC_MUTEX_HPP +#include #include +#include #include +#include #include #include +#include #include #include +#include +#include #include #include diff --git a/include/async_mqtt5/detail/channel_traits.hpp b/include/async_mqtt5/detail/channel_traits.hpp index af0ffcc..ae0517b 100644 --- a/include/async_mqtt5/detail/channel_traits.hpp +++ b/include/async_mqtt5/detail/channel_traits.hpp @@ -9,6 +9,7 @@ #define ASYNC_MQTT5_CHANNEL_TRAITS_HPP #include +#include #include diff --git a/include/async_mqtt5/detail/control_packet.hpp b/include/async_mqtt5/detail/control_packet.hpp index e51c466..c7103f1 100644 --- a/include/async_mqtt5/detail/control_packet.hpp +++ b/include/async_mqtt5/detail/control_packet.hpp @@ -9,6 +9,10 @@ #define ASYNC_MQTT5_CONTROL_PACKET_HPP #include +#include +#include +#include +#include #include #include diff --git a/include/async_mqtt5/detail/internal_types.hpp b/include/async_mqtt5/detail/internal_types.hpp index fa1d922..5d62d01 100644 --- a/include/async_mqtt5/detail/internal_types.hpp +++ b/include/async_mqtt5/detail/internal_types.hpp @@ -8,9 +8,10 @@ #ifndef ASYNC_MQTT5_INTERNAL_TYPES_HPP #define ASYNC_MQTT5_INTERNAL_TYPES_HPP +#include +#include #include #include -#include #include diff --git a/include/async_mqtt5/detail/topic_validation.hpp b/include/async_mqtt5/detail/topic_validation.hpp index 9f83c54..79d934c 100644 --- a/include/async_mqtt5/detail/topic_validation.hpp +++ b/include/async_mqtt5/detail/topic_validation.hpp @@ -8,7 +8,8 @@ #ifndef ASYNC_MQTT5_TOPIC_VALIDATION_HPP #define ASYNC_MQTT5_TOPIC_VALIDATION_HPP -#include +#include +#include #include diff --git a/include/async_mqtt5/detail/utf8_mqtt.hpp b/include/async_mqtt5/detail/utf8_mqtt.hpp index ba0c9c7..5939898 100644 --- a/include/async_mqtt5/detail/utf8_mqtt.hpp +++ b/include/async_mqtt5/detail/utf8_mqtt.hpp @@ -8,7 +8,10 @@ #ifndef ASYNC_MQTT5_UTF8_MQTT_HPP #define ASYNC_MQTT5_UTF8_MQTT_HPP +#include #include +#include +#include namespace async_mqtt5::detail { diff --git a/include/async_mqtt5/error.hpp b/include/async_mqtt5/error.hpp index 8d1e9c4..87ef7d1 100644 --- a/include/async_mqtt5/error.hpp +++ b/include/async_mqtt5/error.hpp @@ -8,6 +8,10 @@ #ifndef ASYNC_MQTT5_ERROR_HPP #define ASYNC_MQTT5_ERROR_HPP +#include +#include +#include + #include namespace async_mqtt5 { diff --git a/include/async_mqtt5/impl/assemble_op.hpp b/include/async_mqtt5/impl/assemble_op.hpp index a27380e..8832090 100644 --- a/include/async_mqtt5/impl/assemble_op.hpp +++ b/include/async_mqtt5/impl/assemble_op.hpp @@ -8,15 +8,18 @@ #ifndef ASYNC_MQTT5_ASSEMBLE_OP_HPP #define ASYNC_MQTT5_ASSEMBLE_OP_HPP +#include +#include #include +#include #include #include #include #include -#include #include #include +#include #include diff --git a/include/async_mqtt5/impl/async_sender.hpp b/include/async_mqtt5/impl/async_sender.hpp index 53dca4e..471f000 100644 --- a/include/async_mqtt5/impl/async_sender.hpp +++ b/include/async_mqtt5/impl/async_sender.hpp @@ -8,13 +8,21 @@ #ifndef ASYNC_MQTT5_ASYNC_SENDER_HPP #define ASYNC_MQTT5_ASYNC_SENDER_HPP +#include +#include +#include +#include + #include +#include #include #include #include +#include #include #include -#include +#include +#include #include diff --git a/include/async_mqtt5/impl/autoconnect_stream.hpp b/include/async_mqtt5/impl/autoconnect_stream.hpp index 785e730..88ed696 100644 --- a/include/async_mqtt5/impl/autoconnect_stream.hpp +++ b/include/async_mqtt5/impl/autoconnect_stream.hpp @@ -8,9 +8,15 @@ #ifndef ASYNC_MQTT5_AUTOCONNECT_STREAM_HPP #define ASYNC_MQTT5_AUTOCONNECT_STREAM_HPP +#include +#include +#include #include +#include +#include #include +#include #include #include diff --git a/include/async_mqtt5/impl/client_service.hpp b/include/async_mqtt5/impl/client_service.hpp index 655d160..f3aeacd 100644 --- a/include/async_mqtt5/impl/client_service.hpp +++ b/include/async_mqtt5/impl/client_service.hpp @@ -8,11 +8,20 @@ #ifndef ASYNC_MQTT5_CLIENT_SERVICE_HPP #define ASYNC_MQTT5_CLIENT_SERVICE_HPP +#include +#include +#include +#include #include +#include +#include +#include #include #include +#include + #include #include @@ -24,7 +33,6 @@ #include #include - namespace async_mqtt5::detail { namespace asio = boost::asio; diff --git a/include/async_mqtt5/impl/codecs/base_decoders.hpp b/include/async_mqtt5/impl/codecs/base_decoders.hpp index 292c194..1bfe8e5 100644 --- a/include/async_mqtt5/impl/codecs/base_decoders.hpp +++ b/include/async_mqtt5/impl/codecs/base_decoders.hpp @@ -8,9 +8,15 @@ #ifndef ASYNC_MQTT5_BASE_DECODERS_HPP #define ASYNC_MQTT5_BASE_DECODERS_HPP +#include +#include +#include + #include #include #include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/codecs/base_encoders.hpp b/include/async_mqtt5/impl/codecs/base_encoders.hpp index 754d21f..e30ee2d 100644 --- a/include/async_mqtt5/impl/codecs/base_encoders.hpp +++ b/include/async_mqtt5/impl/codecs/base_encoders.hpp @@ -10,6 +10,9 @@ #include #include +#include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/codecs/message_decoders.hpp b/include/async_mqtt5/impl/codecs/message_decoders.hpp index 391d7ad..d133dba 100644 --- a/include/async_mqtt5/impl/codecs/message_decoders.hpp +++ b/include/async_mqtt5/impl/codecs/message_decoders.hpp @@ -9,8 +9,12 @@ #define ASYNC_MQTT5_MESSAGE_DECODERS_HPP #include +#include #include +#include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/codecs/message_encoders.hpp b/include/async_mqtt5/impl/codecs/message_encoders.hpp index 751f9d3..0559b04 100644 --- a/include/async_mqtt5/impl/codecs/message_encoders.hpp +++ b/include/async_mqtt5/impl/codecs/message_encoders.hpp @@ -8,8 +8,11 @@ #ifndef ASYNC_MQTT5_MESSAGE_ENCODERS_HPP #define ASYNC_MQTT5_MESSAGE_ENCODERS_HPP -#include +#include #include +#include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/codecs/traits.hpp b/include/async_mqtt5/impl/codecs/traits.hpp index 0d7bff5..715f265 100644 --- a/include/async_mqtt5/impl/codecs/traits.hpp +++ b/include/async_mqtt5/impl/codecs/traits.hpp @@ -10,12 +10,12 @@ #include #include +#include #include #include #include - namespace async_mqtt5 { template @@ -58,8 +58,6 @@ constexpr bool is_boost_iterator = is_specialization< boost::remove_cv_ref_t, boost::iterator_range >; - - } // end namespace async_mqtt5 #endif // !ASYNC_MQTT5_TRAITS_HPP diff --git a/include/async_mqtt5/impl/connect_op.hpp b/include/async_mqtt5/impl/connect_op.hpp index 9c9eb93..be227a2 100644 --- a/include/async_mqtt5/impl/connect_op.hpp +++ b/include/async_mqtt5/impl/connect_op.hpp @@ -8,6 +8,11 @@ #ifndef ASYNC_MQTT5_CONNECT_OP_HPP #define ASYNC_MQTT5_CONNECT_OP_HPP +#include +#include +#include + +#include #include #include #include @@ -16,11 +21,11 @@ #include #include #include +#include #include #include #include #include -#include #include #include @@ -74,8 +79,8 @@ public: _handler(std::forward(handler)), _cancellation_state( asio::get_associated_cancellation_slot(_handler), - asio::enable_total_cancellation{}, - asio::enable_total_cancellation{} + asio::enable_total_cancellation {}, + asio::enable_total_cancellation {} ) {} diff --git a/include/async_mqtt5/impl/disconnect_op.hpp b/include/async_mqtt5/impl/disconnect_op.hpp index 6f38c31..47d2897 100644 --- a/include/async_mqtt5/impl/disconnect_op.hpp +++ b/include/async_mqtt5/impl/disconnect_op.hpp @@ -8,11 +8,17 @@ #ifndef ASYNC_MQTT5_DISCONNECT_OP_HPP #define ASYNC_MQTT5_DISCONNECT_OP_HPP +#include +#include + +#include #include #include #include +#include #include #include +#include #include #include #include diff --git a/include/async_mqtt5/impl/endpoints.hpp b/include/async_mqtt5/impl/endpoints.hpp index 2d022fa..6094ed6 100644 --- a/include/async_mqtt5/impl/endpoints.hpp +++ b/include/async_mqtt5/impl/endpoints.hpp @@ -8,12 +8,17 @@ #ifndef ASYNC_MQTT5_ENDPOINTS_HPP #define ASYNC_MQTT5_ENDPOINTS_HPP +#include +#include +#include + #include #include #include #include +#include #include -#include +#include #include #include #include diff --git a/include/async_mqtt5/impl/ping_op.hpp b/include/async_mqtt5/impl/ping_op.hpp index ffce930..b5252b5 100644 --- a/include/async_mqtt5/impl/ping_op.hpp +++ b/include/async_mqtt5/impl/ping_op.hpp @@ -68,7 +68,7 @@ public: } using cancellation_slot_type = asio::cancellation_slot; - asio::cancellation_slot get_cancellation_slot() const noexcept { + cancellation_slot_type get_cancellation_slot() const noexcept { return _cancellation_state.slot(); } diff --git a/include/async_mqtt5/impl/publish_rec_op.hpp b/include/async_mqtt5/impl/publish_rec_op.hpp index 94cb4f2..f827af6 100644 --- a/include/async_mqtt5/impl/publish_rec_op.hpp +++ b/include/async_mqtt5/impl/publish_rec_op.hpp @@ -8,6 +8,8 @@ #ifndef ASYNC_MQTT5_PUBLISH_REC_OP_HPP #define ASYNC_MQTT5_PUBLISH_REC_OP_HPP +#include +#include #include #include @@ -18,6 +20,7 @@ #include #include #include +#include #include #include diff --git a/include/async_mqtt5/impl/publish_send_op.hpp b/include/async_mqtt5/impl/publish_send_op.hpp index ced7f5f..26c4941 100644 --- a/include/async_mqtt5/impl/publish_send_op.hpp +++ b/include/async_mqtt5/impl/publish_send_op.hpp @@ -8,8 +8,15 @@ #ifndef ASYNC_MQTT5_PUBLISH_SEND_OP_HPP #define ASYNC_MQTT5_PUBLISH_SEND_OP_HPP +#include +#include +#include +#include + #include #include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/re_auth_op.hpp b/include/async_mqtt5/impl/re_auth_op.hpp index 10fb414..c6fbb31 100644 --- a/include/async_mqtt5/impl/re_auth_op.hpp +++ b/include/async_mqtt5/impl/re_auth_op.hpp @@ -8,18 +8,22 @@ #ifndef ASYNC_MQTT5_RE_AUTH_OP_hpp #define ASYNC_MQTT5_RE_AUTH_OP_hpp +#include +#include + #include +#include #include #include #include +#include #include #include #include #include - #include namespace async_mqtt5::detail { diff --git a/include/async_mqtt5/impl/read_message_op.hpp b/include/async_mqtt5/impl/read_message_op.hpp index 516ab9f..7be4893 100644 --- a/include/async_mqtt5/impl/read_message_op.hpp +++ b/include/async_mqtt5/impl/read_message_op.hpp @@ -9,7 +9,10 @@ #define ASYNC_MQTT5_READ_MESSAGE_OP_HPP #include +#include +#include +#include #include #include diff --git a/include/async_mqtt5/impl/read_op.hpp b/include/async_mqtt5/impl/read_op.hpp index 00eda20..3745f10 100644 --- a/include/async_mqtt5/impl/read_op.hpp +++ b/include/async_mqtt5/impl/read_op.hpp @@ -8,9 +8,12 @@ #ifndef ASYNC_MQTT5_READ_OP_HPP #define ASYNC_MQTT5_READ_OP_HPP +#include + #include #include #include +#include #include #include diff --git a/include/async_mqtt5/impl/reconnect_op.hpp b/include/async_mqtt5/impl/reconnect_op.hpp index 01f52ad..568dbf0 100644 --- a/include/async_mqtt5/impl/reconnect_op.hpp +++ b/include/async_mqtt5/impl/reconnect_op.hpp @@ -8,14 +8,21 @@ #ifndef ASYNC_MQTT5_RECONNECT_OP_HPP #define ASYNC_MQTT5_RECONNECT_OP_HPP +#include +#include +#include +#include + +#include #include #include #include +#include #include #include +#include #include #include -#include #include #include diff --git a/include/async_mqtt5/impl/replies.hpp b/include/async_mqtt5/impl/replies.hpp index 93f3e44..4614761 100644 --- a/include/async_mqtt5/impl/replies.hpp +++ b/include/async_mqtt5/impl/replies.hpp @@ -8,14 +8,23 @@ #ifndef ASYNC_MQTT5_REPLIES_HPP #define ASYNC_MQTT5_REPLIES_HPP +#include +#include +#include +#include +#include +#include + #include #include +#include #include #include #include #include #include +#include #include #include diff --git a/include/async_mqtt5/impl/sentry_op.hpp b/include/async_mqtt5/impl/sentry_op.hpp index 1eafebd..abc7e23 100644 --- a/include/async_mqtt5/impl/sentry_op.hpp +++ b/include/async_mqtt5/impl/sentry_op.hpp @@ -9,6 +9,7 @@ #define ASYNC_MQTT5_SENTRY_OP_HPP #include +#include #include #include @@ -61,7 +62,7 @@ public: } using cancellation_slot_type = asio::cancellation_slot; - asio::cancellation_slot get_cancellation_slot() const noexcept { + cancellation_slot_type get_cancellation_slot() const noexcept { return _svc_ptr->_cancel_sentry.slot(); } diff --git a/include/async_mqtt5/impl/subscribe_op.hpp b/include/async_mqtt5/impl/subscribe_op.hpp index 7b87a0b..a7b0575 100644 --- a/include/async_mqtt5/impl/subscribe_op.hpp +++ b/include/async_mqtt5/impl/subscribe_op.hpp @@ -8,12 +8,18 @@ #ifndef ASYNC_MQTT5_SUBSCRIBE_OP_HPP #define ASYNC_MQTT5_SUBSCRIBE_OP_HPP -#include #include +#include +#include +#include #include +#include #include +#include +#include #include +#include #include #include diff --git a/include/async_mqtt5/impl/unsubscribe_op.hpp b/include/async_mqtt5/impl/unsubscribe_op.hpp index 8ba3c9a..580243e 100644 --- a/include/async_mqtt5/impl/unsubscribe_op.hpp +++ b/include/async_mqtt5/impl/unsubscribe_op.hpp @@ -8,12 +8,22 @@ #ifndef ASYNC_MQTT5_UNSUBSCRIBE_OP_HPP #define ASYNC_MQTT5_UNSUBSCRIBE_OP_HPP +#include +#include +#include +#include + #include +#include #include +#include +#include #include +#include #include #include +#include #include #include @@ -31,6 +41,7 @@ namespace asio = boost::asio; template class unsubscribe_op { using client_service = ClientService; + struct on_unsubscribe {}; struct on_unsuback {}; diff --git a/include/async_mqtt5/impl/write_op.hpp b/include/async_mqtt5/impl/write_op.hpp index f59175b..0c3220a 100644 --- a/include/async_mqtt5/impl/write_op.hpp +++ b/include/async_mqtt5/impl/write_op.hpp @@ -10,10 +10,11 @@ #include #include -#include +#include #include #include #include +#include #include diff --git a/include/async_mqtt5/mqtt_client.hpp b/include/async_mqtt5/mqtt_client.hpp index e7f8f72..5f442d9 100644 --- a/include/async_mqtt5/mqtt_client.hpp +++ b/include/async_mqtt5/mqtt_client.hpp @@ -8,6 +8,12 @@ #ifndef ASYNC_MQTT5_MQTT_CLIENT_HPP #define ASYNC_MQTT5_MQTT_CLIENT_HPP +#include +#include +#include +#include // std::monostate +#include + #include #include diff --git a/include/async_mqtt5/property_types.hpp b/include/async_mqtt5/property_types.hpp index 78e0dbb..aca5a09 100644 --- a/include/async_mqtt5/property_types.hpp +++ b/include/async_mqtt5/property_types.hpp @@ -9,8 +9,10 @@ #define ASYNC_MQTT5_PROPERTY_TYPES_HPP #include +#include #include #include +#include #include #include diff --git a/include/async_mqtt5/reason_codes.hpp b/include/async_mqtt5/reason_codes.hpp index 779df38..a54909f 100644 --- a/include/async_mqtt5/reason_codes.hpp +++ b/include/async_mqtt5/reason_codes.hpp @@ -9,8 +9,11 @@ #define ASYNC_MQTT5_REASON_CODES_HPP #include +#include #include #include +#include +#include namespace async_mqtt5 { diff --git a/test/include/test_common/message_exchange.hpp b/test/include/test_common/message_exchange.hpp index 5ae45bb..e6bcfac 100644 --- a/test/include/test_common/message_exchange.hpp +++ b/test/include/test_common/message_exchange.hpp @@ -8,12 +8,16 @@ #ifndef ASYNC_MQTT5_TEST_MESSAGE_EXCHANGE_HPP #define ASYNC_MQTT5_TEST_MESSAGE_EXCHANGE_HPP +#include #include +#include #include #include #include +#include #include +#include #include #include "test_common/delayed_op.hpp" diff --git a/test/include/test_common/packet_util.hpp b/test/include/test_common/packet_util.hpp index 616bdcb..f7eb7cc 100644 --- a/test/include/test_common/packet_util.hpp +++ b/test/include/test_common/packet_util.hpp @@ -9,19 +9,20 @@ #define ASYNC_MQTT5_TEST_PACKET_UTIL_HPP #include +#include #include #include +#include +#include #include - #include - #include #include - #include #include +#include namespace async_mqtt5::test { diff --git a/test/include/test_common/test_authenticators.hpp b/test/include/test_common/test_authenticators.hpp index 7370c6c..1818c35 100644 --- a/test/include/test_common/test_authenticators.hpp +++ b/test/include/test_common/test_authenticators.hpp @@ -8,13 +8,16 @@ #ifndef ASYNC_MQTT5_TEST_TEST_AUTHENTICATORS_HPP #define ASYNC_MQTT5_TEST_TEST_AUTHENTICATORS_HPP +#include +#include + +#include #include #include +#include #include -#include - namespace async_mqtt5::test { namespace asio = boost::asio; diff --git a/test/include/test_common/test_service.hpp b/test/include/test_common/test_service.hpp index e8fc680..6682dd0 100644 --- a/test/include/test_common/test_service.hpp +++ b/test/include/test_common/test_service.hpp @@ -8,10 +8,14 @@ #ifndef ASYNC_MQTT5_TEST_TEST_SERVICE_HPP #define ASYNC_MQTT5_TEST_TEST_SERVICE_HPP +#include +#include + #include -#include +#include #include #include +#include #include @@ -32,11 +36,11 @@ class test_service : public async_mqtt5::detail::client_service (std::move(initiation), token); + return asio::async_initiate( + std::move(initiation), token + ); } template diff --git a/test/include/test_common/test_stream.hpp b/test/include/test_common/test_stream.hpp index 1e0966e..5175ade 100644 --- a/test/include/test_common/test_stream.hpp +++ b/test/include/test_common/test_stream.hpp @@ -8,14 +8,19 @@ #ifndef ASYNC_MQTT5_TEST_TEST_STREAM_HPP #define ASYNC_MQTT5_TEST_TEST_STREAM_HPP +#include +#include + #include +#include #include #include #include #include +#include #include - #include +#include #include diff --git a/test/integration/async_sender.cpp b/test/integration/async_sender.cpp index c12d8ee..2597ea3 100644 --- a/test/integration/async_sender.cpp +++ b/test/integration/async_sender.cpp @@ -5,12 +5,19 @@ // (See accompanying file LICENSE or copy at http://www.boost.org/LICENSE_1_0.txt) // +#include +#include +#include +#include +#include + #include #include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/test_service.hpp" @@ -55,7 +62,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; BOOST_FIXTURE_TEST_CASE(publish_ordering_after_reconnect, shared_test_data) { constexpr int expected_handlers_called = 2; diff --git a/test/integration/cancellation.cpp b/test/integration/cancellation.cpp index f7158cc..b21947a 100644 --- a/test/integration/cancellation.cpp +++ b/test/integration/cancellation.cpp @@ -5,6 +5,8 @@ // (See accompanying file LICENSE or copy at http://www.boost.org/LICENSE_1_0.txt) // +#include + #include #include @@ -15,6 +17,7 @@ #include #include #include +#include #include @@ -272,7 +275,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; #ifdef BOOST_ASIO_HAS_CO_AWAIT diff --git a/test/integration/client.cpp b/test/integration/client.cpp index 4df7f40..ff5f408 100644 --- a/test/integration/client.cpp +++ b/test/integration/client.cpp @@ -10,6 +10,8 @@ #include #ifdef BOOST_ASIO_HAS_CO_AWAIT +#include + #include #include #include @@ -19,6 +21,8 @@ #include +#include + #include namespace boost::beast::websocket { diff --git a/test/integration/client_functions.cpp b/test/integration/client_functions.cpp index 4775162..f7214b0 100644 --- a/test/integration/client_functions.cpp +++ b/test/integration/client_functions.cpp @@ -8,15 +8,21 @@ #include #include +#include #include +#include #include +#include #include #include #include +#include + #include +#include #include "test_common/message_exchange.hpp" #include "test_common/packet_util.hpp" @@ -78,7 +84,7 @@ BOOST_AUTO_TEST_CASE(create_client_with_execution_context) { BOOST_CHECK(c.get_executor() == ioc.get_executor()); } -BOOST_AUTO_TEST_CASE(assign_tls_context) { +void assign_tls_context() { // Tests if the tls_context function compiles asio::io_context ioc; @@ -113,7 +119,7 @@ BOOST_FIXTURE_TEST_CASE(assign_credentials, shared_test_data) { ); } -BOOST_FIXTURE_TEST_CASE(assign_credentials_tls_client, shared_test_data) { +void assign_credentials_tls_client() { // Tests if the assign credentials function compiles std::string client_id = "client_id"; @@ -155,7 +161,7 @@ BOOST_FIXTURE_TEST_CASE(assign_will, shared_test_data) { ); } -BOOST_AUTO_TEST_CASE(assign_authenticator) { +void assign_authenticator() { // Tests if the authenticator function compiles asio::io_context ioc; @@ -163,7 +169,7 @@ BOOST_AUTO_TEST_CASE(assign_authenticator) { c.authenticator(test::test_authenticator()); } -BOOST_AUTO_TEST_CASE(assign_authenticator_tls_client) { +void assign_authenticator_tls_client() { // Tests if the authenticator function compiles asio::io_context ioc; @@ -435,7 +441,7 @@ BOOST_FIXTURE_TEST_CASE(connack_property, shared_connack_prop_test_data) { ); } -BOOST_FIXTURE_TEST_CASE(connack_property_with_tls_client, shared_connack_prop_test_data) { +void connack_property_with_tls_client() { // Tests if the connack_properties & connack_property functions compile asio::io_context ioc; diff --git a/test/integration/disconnect.cpp b/test/integration/disconnect.cpp index 64bfff3..6b4b8da 100644 --- a/test/integration/disconnect.cpp +++ b/test/integration/disconnect.cpp @@ -7,11 +7,15 @@ #include +#include +#include + #include #include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/test_broker.hpp" diff --git a/test/integration/executors.cpp b/test/integration/executors.cpp index 00f8e8c..7c9dc13 100644 --- a/test/integration/executors.cpp +++ b/test/integration/executors.cpp @@ -7,11 +7,15 @@ #include +#include #include +#include +#include -#include #include #include +#include +#include #include #include @@ -30,7 +34,7 @@ BOOST_AUTO_TEST_SUITE(executors) BOOST_AUTO_TEST_CASE(bind_executor) { using test::after; - using namespace std::chrono; + using namespace std::chrono_literals; constexpr int expected_handlers_called = 8; int handlers_called = 0; diff --git a/test/integration/mqtt_features.cpp b/test/integration/mqtt_features.cpp index cf8dd60..762a717 100644 --- a/test/integration/mqtt_features.cpp +++ b/test/integration/mqtt_features.cpp @@ -10,12 +10,15 @@ #include #ifdef BOOST_ASIO_HAS_CO_AWAIT +#include +#include +#include + #include #include #include #include #include - #include #include diff --git a/test/integration/ping.cpp b/test/integration/ping.cpp index 1f02930..bce2105 100644 --- a/test/integration/ping.cpp +++ b/test/integration/ping.cpp @@ -5,13 +5,19 @@ // (See accompanying file LICENSE or copy at http://www.boost.org/LICENSE_1_0.txt) // -#include - #include +#include +#include +#include +#include +#include + +#include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/test_service.hpp" @@ -34,7 +40,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; std::string connect_with_keep_alive(uint16_t keep_alive) { return encoders::encode_connect( diff --git a/test/integration/re_authentication.cpp b/test/integration/re_authentication.cpp index 0e83147..3c84103 100644 --- a/test/integration/re_authentication.cpp +++ b/test/integration/re_authentication.cpp @@ -7,10 +7,18 @@ #include +#include +#include +#include +#include +#include + +#include #include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/packet_util.hpp" @@ -59,7 +67,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; template void run_test( diff --git a/test/integration/read_message.cpp b/test/integration/read_message.cpp index c681fea..57076dd 100644 --- a/test/integration/read_message.cpp +++ b/test/integration/read_message.cpp @@ -7,9 +7,17 @@ #include +#include +#include +#include + #include +#include +#include +#include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/test_service.hpp" @@ -20,7 +28,7 @@ using namespace async_mqtt5; BOOST_AUTO_TEST_SUITE(read_message/*, *boost::unit_test::disabled()*/) using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; void test_receive_malformed_packet( std::string malformed_packet, std::string reason_string diff --git a/test/integration/receive_publish.cpp b/test/integration/receive_publish.cpp index 89e5833..bac0a6e 100644 --- a/test/integration/receive_publish.cpp +++ b/test/integration/receive_publish.cpp @@ -7,11 +7,18 @@ #include +#include +#include +#include + #include #include #include +#include + #include +#include #include "test_common/message_exchange.hpp" #include "test_common/packet_util.hpp" @@ -55,7 +62,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; void run_test( test::msg_exchange broker_side, connect_props cprops = {} diff --git a/test/integration/send_publish.cpp b/test/integration/send_publish.cpp index 8d192da..0b7e94b 100644 --- a/test/integration/send_publish.cpp +++ b/test/integration/send_publish.cpp @@ -7,9 +7,18 @@ #include +#include +#include +#include + +#include +#include +#include +#include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/packet_util.hpp" @@ -52,7 +61,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; template void run_test( diff --git a/test/integration/sub_unsub.cpp b/test/integration/sub_unsub.cpp index c8a390b..2de5884 100644 --- a/test/integration/sub_unsub.cpp +++ b/test/integration/sub_unsub.cpp @@ -7,12 +7,19 @@ #include +#include +#include +#include +#include + #include #include #include +#include #include #include +#include #include "test_common/message_exchange.hpp" #include "test_common/packet_util.hpp" @@ -61,7 +68,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; template void run_test(test::msg_exchange broker_side) { diff --git a/test/unit/async_mutex.cpp b/test/unit/async_mutex.cpp index e17f163..8d8310b 100644 --- a/test/unit/async_mutex.cpp +++ b/test/unit/async_mutex.cpp @@ -7,11 +7,17 @@ #include +#include +#include +#include + #include +#include #include #include #include +#include #include using namespace async_mqtt5; diff --git a/test/unit/connect_op.cpp b/test/unit/connect_op.cpp index 872a397..1607a93 100644 --- a/test/unit/connect_op.cpp +++ b/test/unit/connect_op.cpp @@ -7,16 +7,18 @@ #include +#include +#include +#include +#include + #include #include - #include -#include - -#include - #include +#include +#include #include "test_common/test_authenticators.hpp" #include "test_common/test_stream.hpp" @@ -38,7 +40,7 @@ struct shared_test_data { }; using test::after; -using namespace std::chrono; +using namespace std::chrono_literals; void run_unit_test( detail::mqtt_ctx mqtt_ctx, test::msg_exchange broker_side, diff --git a/test/unit/default_completion_tokens.cpp b/test/unit/default_completion_tokens.cpp index b2bd1d1..e955575 100644 --- a/test/unit/default_completion_tokens.cpp +++ b/test/unit/default_completion_tokens.cpp @@ -10,14 +10,15 @@ #ifdef BOOST_ASIO_HAS_CO_AWAIT +#include #include #include // std::monostate #include #include - #include #include + #include #include // async_teardown for asio::ssl::socket diff --git a/test/unit/disconnect_op.cpp b/test/unit/disconnect_op.cpp index 0a5a595..d18baa2 100644 --- a/test/unit/disconnect_op.cpp +++ b/test/unit/disconnect_op.cpp @@ -7,8 +7,15 @@ #include -#include +#include +#include +#include +#include +#include +#include + +#include #include #include "test_common/test_service.hpp" diff --git a/test/unit/error.cpp b/test/unit/error.cpp index 07658b2..262c775 100644 --- a/test/unit/error.cpp +++ b/test/unit/error.cpp @@ -7,7 +7,8 @@ #include -#include +#include +#include #include #include diff --git a/test/unit/publish_send_op.cpp b/test/unit/publish_send_op.cpp index 8fa0b9e..5332d6a 100644 --- a/test/unit/publish_send_op.cpp +++ b/test/unit/publish_send_op.cpp @@ -7,10 +7,19 @@ #include +#include +#include +#include +#include +#include + #include #include #include #include +#include + +#include #include #include diff --git a/test/unit/reconnect_op.cpp b/test/unit/reconnect_op.cpp index 7ff3e65..bc7a2bc 100644 --- a/test/unit/reconnect_op.cpp +++ b/test/unit/reconnect_op.cpp @@ -7,7 +7,8 @@ #include -#include +#include + #include #include diff --git a/test/unit/serialization.cpp b/test/unit/serialization.cpp index a137517..a8c9697 100644 --- a/test/unit/serialization.cpp +++ b/test/unit/serialization.cpp @@ -7,6 +7,12 @@ #include +#include +#include +#include +#include +#include + #include #include diff --git a/test/unit/session.cpp b/test/unit/session.cpp index dc5412f..f08ba50 100644 --- a/test/unit/session.cpp +++ b/test/unit/session.cpp @@ -7,6 +7,14 @@ #include +#include +#include +#include + +#include +#include +#include + #include #include diff --git a/test/unit/subscribe_op.cpp b/test/unit/subscribe_op.cpp index e0bb246..44a182d 100644 --- a/test/unit/subscribe_op.cpp +++ b/test/unit/subscribe_op.cpp @@ -7,8 +7,16 @@ #include -#include +#include +#include +#include +#include +#include +#include +#include + +#include #include #include "test_common/test_service.hpp" diff --git a/test/unit/unsubscribe_op.cpp b/test/unit/unsubscribe_op.cpp index d08fea4..21241c3 100644 --- a/test/unit/unsubscribe_op.cpp +++ b/test/unit/unsubscribe_op.cpp @@ -7,8 +7,16 @@ #include -#include +#include +#include +#include +#include +#include +#include +#include + +#include #include #include "test_common/test_service.hpp"