commit | f96f7cf7294f08af290f09466981ed01a5fe1071 | [log] [tgz] |
---|---|---|
author | HIGUCHI Yuta <y-higuchi@ak.jp.nec.com> | Sat May 21 12:32:31 2016 -0700 |
committer | Gerrit Code Review <gerrit@onlab.us> | Sun May 22 20:22:40 2016 +0000 |
tree | 76f27778521c0b0d833d194fdb5d8e29cec25086 | |
parent | 07e9d415708400046aa489bfd0d5129717be3695 [diff] |
Remove unnecessary delay in CounterTest. Change-Id: I5a29c88f803c2d01f9b4f502b64ad4d1460b977b
diff --git a/utils/misc/src/test/java/org/onlab/util/CounterTest.java b/utils/misc/src/test/java/org/onlab/util/CounterTest.java index 963f7db..cb085bb 100644 --- a/utils/misc/src/test/java/org/onlab/util/CounterTest.java +++ b/utils/misc/src/test/java/org/onlab/util/CounterTest.java
@@ -45,10 +45,8 @@ @Test public void freeze() { - Counter tt = new Counter(); - tt.add(123L); - assertEquals("incorrect number of bytes", 123L, tt.total()); - delay(1000); + long now = System.currentTimeMillis(); + Counter tt = new Counter(now, 123L, now + 1000); tt.freeze(); tt.add(123L); assertEquals("incorrect number of bytes", 123L, tt.total());