Index: test/unittests/heap/gc-tracer-unittest.cc |
diff --git a/test/unittests/heap/gc-tracer-unittest.cc b/test/unittests/heap/gc-tracer-unittest.cc |
index b57d4a6e2453e6018fdbbc570c98e148caaa99d2..2bf4d037d3ba4eaaee8975458e3d7224c54ec992 100644 |
--- a/test/unittests/heap/gc-tracer-unittest.cc |
+++ b/test/unittests/heap/gc-tracer-unittest.cc |
@@ -37,11 +37,11 @@ TEST(GCTracer, AverageSpeed) { |
buffer.Push(MakeBytesAndDuration(i + 1, 1)); |
} |
EXPECT_EQ( |
- static_cast<int>(sum * 1.0 / buffer.kSize + 0.5), |
+ sum * 1.0 / buffer.kSize, |
GCTracer::AverageSpeed(buffer, MakeBytesAndDuration(0, 0), buffer.kSize)); |
buffer.Push(MakeBytesAndDuration(100, 1)); |
EXPECT_EQ( |
- static_cast<int>((sum * 1.0 - 1 + 100) / buffer.kSize + 0.5), |
+ (sum * 1.0 - 1 + 100) / buffer.kSize, |
GCTracer::AverageSpeed(buffer, MakeBytesAndDuration(0, 0), buffer.kSize)); |
} |