From 595aeadfd798f9b9d4465d350105c051784b5666 Mon Sep 17 00:00:00 2001
From: QingWang0909 <lucifer0909@gmail.com>
Date: Wed, 31 May 2017 11:37:53 -0400
Subject: [PATCH] removed all the old commented-out code.

---
 .../statistics/StatisticsCollector.java               | 11 -----------
 .../statistics/StatisticsTest.java                    |  2 +-
 2 files changed, 1 insertion(+), 12 deletions(-)

diff --git a/src/main/java/net/floodlightcontroller/statistics/StatisticsCollector.java b/src/main/java/net/floodlightcontroller/statistics/StatisticsCollector.java
index 58ce31b0c..e329f2b5d 100644
--- a/src/main/java/net/floodlightcontroller/statistics/StatisticsCollector.java
+++ b/src/main/java/net/floodlightcontroller/statistics/StatisticsCollector.java
@@ -124,17 +124,6 @@ public class StatisticsCollector implements IFloodlightModule, IStatisticsServic
 			}
 		}
 
-		/* This is the original Code with Bugs */
-//		protected  long getSpeed(NodePortTuple npt) {
-//			IOFSwitch sw = switchService.getSwitch(npt.getNodeId());
-//			long speed = 0;
-//			if(sw != null){
-//				speed = sw.getPort(npt.getPortId()).getCurrSpeed();
-//			}
-//			return speed;
-//		}
-
-		/* Fix bug from here */
 		protected long getSpeed(NodePortTuple npt) {
 			IOFSwitch sw = switchService.getSwitch(npt.getNodeId());
 			long speed = 0;
diff --git a/src/test/java/net/floodlightcontroller/statistics/StatisticsTest.java b/src/test/java/net/floodlightcontroller/statistics/StatisticsTest.java
index 5c20dcb92..177ecbb2c 100644
--- a/src/test/java/net/floodlightcontroller/statistics/StatisticsTest.java
+++ b/src/test/java/net/floodlightcontroller/statistics/StatisticsTest.java
@@ -72,7 +72,7 @@ public class StatisticsTest extends FloodlightTestCase {
      * A Collection of Junit Test with various "inputFactory" and "expectedSpeed"
      * @return
      */
-    @Parameterized.Parameters
+    @Parameterized.Parameters(name = "Test {index}: {0}, Port Speed is {1}")
     public static Iterable<Object[]> testData() {
         return Arrays.asList(new Object[][] {
             { OFVersion.OF_11, 100L },
-- 
GitLab