mirror of
https://github.com/XRPLF/rippled.git
synced 2026-04-29 15:37:57 +00:00
updates asio transport base unit tests for new interface
This commit is contained in:
@@ -18,7 +18,7 @@ prgs = env.Program('test_base_boost', ["base_boost.o"], LIBS = BOOST_LIBS)
|
||||
#prgs += env.Program('test_utility_boost', ["utilities_boost.o"], LIBS = BOOST_LIBS)
|
||||
|
||||
if env_cpp11.has_key('WSPP_CPP11_ENABLED'):
|
||||
BOOST_LIBS_CPP11 = boostlibs(['unit_test_framework'],env_cpp11) + [platform_libs] + [polyfill_libs]
|
||||
BOOST_LIBS_CPP11 = boostlibs(['unit_test_framework','system'],env_cpp11) + [platform_libs] + [polyfill_libs]
|
||||
objs += env_cpp11.Object('base_stl.o', ["base.cpp"], LIBS = BOOST_LIBS_CPP11)
|
||||
prgs += env_cpp11.Program('test_base_stl', ["base_stl.o"], LIBS = BOOST_LIBS_CPP11)
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2011, Peter Thorson. All rights reserved.
|
||||
* Copyright (c) 2013, Peter Thorson. All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
@@ -33,17 +33,17 @@
|
||||
#include <websocketpp/transport/asio/base.hpp>
|
||||
|
||||
BOOST_AUTO_TEST_CASE( blank_error ) {
|
||||
websocketpp::lib::error_code ec;
|
||||
|
||||
websocketpp::lib::error_code ec;
|
||||
|
||||
BOOST_CHECK( !ec );
|
||||
}
|
||||
|
||||
BOOST_AUTO_TEST_CASE( asio_error ) {
|
||||
using websocketpp::transport::asio::error::make_error_code;
|
||||
using websocketpp::transport::asio::error::general;
|
||||
|
||||
websocketpp::lib::error_code ec = make_error_code(general);
|
||||
|
||||
using websocketpp::transport::asio::error::make_error_code;
|
||||
using websocketpp::transport::asio::error::general;
|
||||
|
||||
websocketpp::lib::error_code ec = make_error_code(general);
|
||||
|
||||
BOOST_CHECK( ec == general );
|
||||
BOOST_CHECK( ec.value() == 1 );
|
||||
}
|
||||
Reference in New Issue
Block a user