mirror of
https://github.com/boostorg/test.git
synced 2026-02-12 00:22:18 +00:00
42e9a15317c9b89665c3b6aca443ff4d7daa8afb
As boost/timer.hpp is being deprecated, and the needed functionality is very little, reimplemeted naively a timing class for the purpose of measuring the test-unit time. - specific timer class that is cross-platform and agnostic to changes made to the OS while measuring time (mac, posix and windows). Wall-clock and system/user time available - changed framework to work fully with microseconds. Only ::alarm needs seconds and ceiling is used for signaling time-out - Windows now signals also time-outs the same way as for other platforms (exception raised in the test and reported). However, Windows platform do not raise a signal that terminates the current test - timeout is not used for failing a test-suite as well. Remaining time calculation is now made in microseconds. Adding an observer interface for signaling time out and adding the time outs in the test results - cleaned up interfaces, clarify the code about the dimension of the different scalar values.
What is Boost.Test?
Boost.Test is a C++03 and C++11/14 unit testing library, available on a wide range of platforms and compilers.
The library is part of Boost. The latest release of the library is available from the boost web site.
Full instructions for use of this library can be accessed from http://www.boost.org/doc/libs/release/libs/test/
Key features
- Easy to get started with:
- download and deflate the latest boost archive
- create a test module with this (header version):
#define BOOST_TEST_MODULE your_test_module #include <boost/test/included/unit_test.hpp> - done
- powerful and unique test assertion macro
BOOST_TEST, that understands floating points, collections, strings... and uses appropriate comparison paradigm - self-registering test cases, organize cases in test suites, apply fixtures on test cases, suites or globally
- provide assertion context for advanced diagnostic on failure
- powerful and extensible dataset tests
- add decoration to test cases and suites for advanced description, group/label, and dependencies
- powerful command line options and test case filters
- extensible logging, XML and JUNIT outputs for third-party tools (eg. cont. integration)
- various usage (shared/static library) for faster compilation/build cycles, smaller binaries
Copyright and license
Copyright 2001-2014, Gennadiy Rozental.
Copyright 2013-2018, Boost.Test team.
Distributed under the Boost Software License, Version 1.0. (Get a copy at www.boost.org/LICENSE_1_0.txt)
Contribute
Please read this document to get started.
Languages
C++
99%
CMake
0.9%
