accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From els...@apache.org
Subject [2/3] accumulo git commit: ACCUMULO-4447 Fix assertion message for 80% of expected max compaction rate
Date Fri, 02 Sep 2016 19:44:46 GMT
ACCUMULO-4447 Fix assertion message for 80% of expected max compaction rate


Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo
Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/fbcaa902
Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/fbcaa902
Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/fbcaa902

Branch: refs/heads/master
Commit: fbcaa90270ec70966e3571ff455f4f3f5e06110a
Parents: be5c433
Author: Josh Elser <elserj@apache.org>
Authored: Fri Sep 2 14:05:41 2016 -0400
Committer: Josh Elser <elserj@apache.org>
Committed: Fri Sep 2 15:44:06 2016 -0400

----------------------------------------------------------------------
 .../java/org/apache/accumulo/test/CompactionRateLimitingIT.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/fbcaa902/test/src/main/java/org/apache/accumulo/test/CompactionRateLimitingIT.java
----------------------------------------------------------------------
diff --git a/test/src/main/java/org/apache/accumulo/test/CompactionRateLimitingIT.java b/test/src/main/java/org/apache/accumulo/test/CompactionRateLimitingIT.java
index 3b218e2..91ed2de 100644
--- a/test/src/main/java/org/apache/accumulo/test/CompactionRateLimitingIT.java
+++ b/test/src/main/java/org/apache/accumulo/test/CompactionRateLimitingIT.java
@@ -76,7 +76,7 @@ public class CompactionRateLimitingIT extends ConfigurableMacBase {
     long duration = System.currentTimeMillis() - compactionStart;
     // The rate will be "bursty", try to account for that by taking 80% of the expected rate
(allow for 20% under the maximum expected duration)
     Assert.assertTrue(
-        String.format("Expected a compaction rate of no more than %,d bytes/sec, but saw
a rate of %,f bytes/sec", RATE, 1000.0 * bytesWritten / duration),
-        duration > 1000L * 0.8 * BYTES_TO_WRITE / RATE);
+        String.format("Expected a compaction rate of no more than %,d bytes/sec, but saw
a rate of %,f bytes/sec", (int) 0.8d * RATE, 1000.0 * bytesWritten
+            / duration), duration > 1000L * 0.8 * BYTES_TO_WRITE / RATE);
   }
 }


Mime
View raw message