diff options
author | Mathieu Chartier <mathieuc@google.com> | 2013-11-20 15:51:12 -0800 |
---|---|---|
committer | Mathieu Chartier <mathieuc@google.com> | 2013-11-20 15:52:07 -0800 |
commit | 3e669dba962dc5291de0642eb46ede107be4e5a4 (patch) | |
tree | 96296f8e66a954e568719fa49bbcec98cb58bc37 /runtime/base | |
parent | cc9e9a375924f5a3de1339818945f1f6ae09becb (diff) | |
download | art-3e669dba962dc5291de0642eb46ede107be4e5a4.zip art-3e669dba962dc5291de0642eb46ede107be4e5a4.tar.gz art-3e669dba962dc5291de0642eb46ede107be4e5a4.tar.bz2 |
Fix histogram test.
The test compares outputted strings for some reason. Forgot to run
it earlier.
Change-Id: I9eed08350d0122614cb2e18ca7195e5dc0832da6
Diffstat (limited to 'runtime/base')
-rw-r--r-- | runtime/base/histogram_test.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/runtime/base/histogram_test.cc b/runtime/base/histogram_test.cc index 9d371f5..966b97f 100644 --- a/runtime/base/histogram_test.cc +++ b/runtime/base/histogram_test.cc @@ -122,7 +122,7 @@ TEST(Histtest, UpdateRange) { std::string text; std::stringstream stream; - std::string expected("UpdateRange:\t99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); + std::string expected("UpdateRange:\tSum: 2.654ms 99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); hist->PrintConfidenceIntervals(stream, 0.99, data); EXPECT_EQ(expected, stream.str()); @@ -165,7 +165,7 @@ TEST(Histtest, Reset) { std::string text; std::stringstream stream; - std::string expected("Reset:\t99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); + std::string expected("Reset:\tSum: 2.654ms 99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); hist->PrintConfidenceIntervals(stream, 0.99, data); EXPECT_EQ(expected, stream.str()); @@ -204,7 +204,7 @@ TEST(Histtest, MultipleCreateHist) { hist->CreateHistogram(&data); PerValue = hist->Percentile(0.50, data); std::stringstream stream; - std::string expected("MultipleCreateHist:\t99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); + std::string expected("MultipleCreateHist:\tSum: 2.654ms 99% C.I. 15us-212us Avg: 126.380us Max: 212us\n"); hist->PrintConfidenceIntervals(stream, 0.99, data); EXPECT_EQ(expected, stream.str()); @@ -219,7 +219,7 @@ TEST(Histtest, SingleValue) { hist->AddValue(1); hist->CreateHistogram(&data); std::stringstream stream; - std::string expected = "SingleValue:\t99% C.I. 1us-1us Avg: 1us Max: 1us\n"; + std::string expected = "SingleValue:\tSum: 1us 99% C.I. 1us-1us Avg: 1us Max: 1us\n"; hist->PrintConfidenceIntervals(stream, 0.99, data); EXPECT_EQ(expected, stream.str()); } @@ -262,7 +262,7 @@ TEST(Histtest, SpikyValues) { hist->AddValue(10000); hist->CreateHistogram(&data); std::stringstream stream; - std::string expected = "SpikyValues:\t99% C.I. 0.089us-2541.825us Avg: 95.033us Max: 10000us\n"; + std::string expected = "SpikyValues:\tSum: 14.350ms 99% C.I. 0.089us-2541.825us Avg: 95.033us Max: 10000us\n"; hist->PrintConfidenceIntervals(stream, 0.99, data); EXPECT_EQ(expected, stream.str()); } |