-
Notifications
You must be signed in to change notification settings - Fork 118
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add the windows-b2-install job to ci.yml
- Loading branch information
Showing
315 changed files
with
123,628 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# Copyright 2018, 2019, 2021 Peter Dimov | ||
# Distributed under the Boost Software License, Version 1.0. | ||
# See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt | ||
|
||
cmake_minimum_required(VERSION 3.5...3.16) | ||
|
||
project(boost_iostreams_install_test LANGUAGES CXX) | ||
|
||
if(BOOST_RUNTIME_LINK STREQUAL "static") | ||
set(CMAKE_MSVC_RUNTIME_LIBRARY "MultiThreaded$<$<CONFIG:Debug>:Debug>") | ||
endif() | ||
|
||
find_package(boost_iostreams REQUIRED) | ||
|
||
add_executable(test_gzip test_gzip.cpp) | ||
target_link_libraries(test_gzip Boost::iostreams) | ||
|
||
add_executable(test_bzip2 test_bzip2.cpp) | ||
target_link_libraries(test_bzip2 Boost::iostreams) | ||
|
||
enable_testing() | ||
add_test(NAME test_gzip COMMAND test_gzip WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) | ||
add_test(NAME test_bzip2 COMMAND test_bzip2 WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) | ||
|
||
add_custom_target(check VERBATIM COMMAND ${CMAKE_CTEST_COMMAND} --output-on-failure --no-tests=error -C $<CONFIG>) |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
|
||
// Copyright 2019 Peter Dimov. | ||
// | ||
// Distributed under the Boost Software License, Version 1.0. | ||
// | ||
// See accompanying file LICENSE_1_0.txt or copy at | ||
// http://www.boost.org/LICENSE_1_0.txt | ||
|
||
#include <boost/iostreams/device/file.hpp> | ||
#include <boost/iostreams/filter/bzip2.hpp> | ||
#include <boost/iostreams/device/back_inserter.hpp> | ||
#include <boost/iostreams/copy.hpp> | ||
#include <boost/iostreams/compose.hpp> | ||
#include <boost/core/lightweight_test.hpp> | ||
|
||
namespace io = boost::iostreams; | ||
|
||
int main() | ||
{ | ||
io::file_source fs( "test.txt.bz2", std::ios_base::binary ); | ||
io::bzip2_decompressor gz; | ||
|
||
std::string s; | ||
io::copy( io::compose( gz, fs ), io::back_inserter( s ) ); | ||
|
||
BOOST_TEST( s == "=== reference output ===" ); | ||
|
||
return boost::report_errors(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
|
||
// Copyright 2019 Peter Dimov. | ||
// | ||
// Distributed under the Boost Software License, Version 1.0. | ||
// | ||
// See accompanying file LICENSE_1_0.txt or copy at | ||
// http://www.boost.org/LICENSE_1_0.txt | ||
|
||
#include <boost/iostreams/device/file.hpp> | ||
#include <boost/iostreams/filter/gzip.hpp> | ||
#include <boost/iostreams/device/back_inserter.hpp> | ||
#include <boost/iostreams/copy.hpp> | ||
#include <boost/iostreams/compose.hpp> | ||
#include <boost/core/lightweight_test.hpp> | ||
|
||
namespace io = boost::iostreams; | ||
|
||
int main() | ||
{ | ||
io::file_source fs( "test.txt.gz", std::ios_base::binary ); | ||
io::gzip_decompressor gz; | ||
|
||
std::string s; | ||
io::copy( io::compose( gz, fs ), io::back_inserter( s ) ); | ||
|
||
BOOST_TEST( s == "=== reference output ===" ); | ||
|
||
return boost::report_errors(); | ||
} |
Oops, something went wrong.