Use Collection.isEmpty (#10525)

Fixes 47 SAT UseCollectionIsEmpty findings.

Signed-off-by: Wouter Born <github@maindrain.net>
This commit is contained in:
Wouter Born
2021-04-15 21:00:47 +02:00
committed by GitHub
parent 7a22d65406
commit 1633c705a1
35 changed files with 67 additions and 68 deletions

View File

@@ -168,7 +168,7 @@ public class HDPowerViewJUnitTests {
@Nullable
List<ShadeData> shadesData = shadesX.shadeData;
assertNotNull(shadesData);
assertTrue(shadesData.size() > 0);
assertTrue(!shadesData.isEmpty());
@Nullable
ShadeData shadeData;
shadeData = shadesData.get(0);
@@ -198,7 +198,7 @@ public class HDPowerViewJUnitTests {
@Nullable
List<Scene> scenesData = scenes.sceneData;
assertNotNull(scenesData);
assertTrue(scenesData.size() > 0);
assertTrue(!scenesData.isEmpty());
@Nullable
Scene sceneZero = scenesData.get(0);
assertNotNull(sceneZero);