Permalink
Browse files

Fixed up ClientSocketStatsTest to match change in return code from -1…

… to 0.
  • Loading branch information...
1 parent 0df53c0 commit bb73de190f39258d773c52ffe9120a90d70cd98c @jayjwylie jayjwylie committed Oct 10, 2012
Showing with 5 additions and 4 deletions.
  1. +5 −4 test/unit/voldemort/store/stats/ClientSocketStatsTest.java
@@ -58,7 +58,7 @@ public void testNewAggrNodeStatsObject() {
assertEquals(0, stats.getConnectionsCreated());
assertEquals(0, stats.getConnectionsDestroyed());
assertEquals(0, stats.getCheckoutCount());
- assertEquals(-1, stats.getAvgCheckoutWaitUs());
+ assertEquals(0, stats.getAvgCheckoutWaitUs());
}
@Test
@@ -312,12 +312,12 @@ public void testSetMonitoringInterval() {
// after interval based reset
stats.recordCheckoutTimeUs(dest2, 900000);
// check parent
- assertEquals(-1, stats.getAvgCheckoutWaitUs());
+ assertEquals(0, stats.getAvgCheckoutWaitUs());
assertEquals(0, stats.getCheckoutCount());
// check child
- assertEquals(-1, child1.getAvgCheckoutWaitUs());
+ assertEquals(0, child1.getAvgCheckoutWaitUs());
assertEquals(0, child1.getCheckoutCount());
- assertEquals(-1, child2.getAvgCheckoutWaitUs());
+ assertEquals(0, child2.getAvgCheckoutWaitUs());
assertEquals(0, child2.getCheckoutCount());
}
@@ -331,6 +331,7 @@ public TestThread(SocketDestination dest) {
this.dest = dest;
}
+ @Override
public void run() {
masterStats.recordCheckoutTimeUs(dest, 1000);
masterStats.recordCheckoutTimeUs(dest, 2000);

0 comments on commit bb73de1

Please sign in to comment.