commit | cbd1b39f584019da9ce26a501eb91cf075ab2902 | [log] [tgz] |
---|---|---|
author | Jon Hall <jhall@ciena.com> | Wed Jan 18 20:15:44 2017 -0800 |
committer | Ray Milkey <ray@onlab.us> | Thu Jan 19 20:24:18 2017 +0000 |
tree | 59a29576180e3242864c1f157e74c82f32487396 | |
parent | 1745e5abbd4cf908579d79af77c3095970095d10 [diff] [blame] |
Sonar fixes Rule: Use isEmpty() to check whether the collection is empty or not. Change-Id: Ib5ab56b2263623b297db56c5cac2c2ee80e12725
diff --git a/apps/test/intent-perf/src/main/java/org/onosproject/intentperf/IntentPerfInstaller.java b/apps/test/intent-perf/src/main/java/org/onosproject/intentperf/IntentPerfInstaller.java index 9b758d4..b4d7acf 100644 --- a/apps/test/intent-perf/src/main/java/org/onosproject/intentperf/IntentPerfInstaller.java +++ b/apps/test/intent-perf/src/main/java/org/onosproject/intentperf/IntentPerfInstaller.java
@@ -358,7 +358,7 @@ .forEach(device -> devices.put(mastershipService.getMasterFor(device.id()), device)); // ensure that we have at least one device per neighbor - neighbors.forEach(node -> checkState(devices.get(node).size() > 0, + neighbors.forEach(node -> checkState(!devices.get(node).isEmpty(), "There are no devices for {}", node)); // TODO pull this outside so that createIntent can use it