JayBeams  0.1
Another project to have fun coding.
ut_histogram_summary.cpp
Go to the documentation of this file.
2 
3 #include <boost/test/unit_test.hpp>
4 
5 /**
6  * @test Verify that a histogram_summary works as expected.
7  */
8 BOOST_AUTO_TEST_CASE(histogram_summary_ios) {
9  jb::histogram_summary summary{0, 25, 50, 75, 90, 99, 100, 1000};
10  std::ostringstream os;
11  os << summary;
12  BOOST_CHECK_EQUAL(
13  os.str(), "nsamples=1000, min=0, p25=25, "
14  "p50=50, p75=75, p90=90, p99=99, max=100");
15 }
A simple class to capture summary information about a histogram.
BOOST_AUTO_TEST_CASE(histogram_summary_ios)