Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'org.eclipse.egit.ui.test/src/org')
-rw-r--r--org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/test/TestUtil.java2
-rw-r--r--org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/MockLogicalResourceMapping.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/test/TestUtil.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/test/TestUtil.java
index a1a698d7a..02bb84488 100644
--- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/test/TestUtil.java
+++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/test/TestUtil.java
@@ -572,7 +572,7 @@ public class TestUtil {
if (project.equals(name))
items.add(item);
}
- return items.isEmpty() ? null : items.toArray(new SWTBotTreeItem[items.size()]);
+ return items.isEmpty() ? null : items.toArray(new SWTBotTreeItem[0]);
}
/**
diff --git a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/MockLogicalResourceMapping.java b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/MockLogicalResourceMapping.java
index 0a9b90a8f..9a51d6397 100644
--- a/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/MockLogicalResourceMapping.java
+++ b/org.eclipse.egit.ui.test/src/org/eclipse/egit/ui/view/synchronize/MockLogicalResourceMapping.java
@@ -95,7 +95,7 @@ public class MockLogicalResourceMapping extends ResourceMapping {
"Exception while computing logical model", e));
}
final IResource[] resourceArray = result
- .toArray(new IResource[result.size()]);
+ .toArray(new IResource[0]);
return new ResourceTraversal[] { new ResourceTraversal(resourceArray,
IResource.DEPTH_ONE, IResource.NONE), };
}

Back to the top