Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEd Merks2020-03-16 06:01:38 +0000
committerEd Merks2020-03-16 06:01:38 +0000
commit2c24f1d79d518a50b667d557e499085f9c37c22d (patch)
treeb0509a1c923642108f73aed67bed59c341889340 /bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository
parent7feb7fa160a7c2226ef264a03ed625c9a4a51a8e (diff)
downloadrt.equinox.p2-2c24f1d79d518a50b667d557e499085f9c37c22d.tar.gz
rt.equinox.p2-2c24f1d79d518a50b667d557e499085f9c37c22d.tar.xz
rt.equinox.p2-2c24f1d79d518a50b667d557e499085f9c37c22d.zip
Bug 561134 - Fix build failure for the used variable in
FileReaderTest.testReadStream() Change-Id: I23fc162662a6cd2d603026f1bcfb78b32620430d Signed-off-by: Ed Merks <ed.merks@gmail.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository')
-rw-r--r--bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository/FileReaderTest.java19
1 files changed, 14 insertions, 5 deletions
diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository/FileReaderTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository/FileReaderTest.java
index 91e03f9aa..fe9276263 100644
--- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository/FileReaderTest.java
+++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/repository/FileReaderTest.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2009, 2017 Cloudsmith Inc and others.
+ * Copyright (c) 2009, 2020 Cloudsmith Inc and others.
*
* This program and the accompanying materials
* are made available under the terms of the Eclipse Public License 2.0
@@ -14,9 +14,16 @@
package org.eclipse.equinox.p2.tests.repository;
-import java.io.*;
-import java.net.*;
-import org.eclipse.core.runtime.*;
+import java.io.ByteArrayOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.OutputStream;
+import java.net.ConnectException;
+import java.net.URI;
+import java.net.URISyntaxException;
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IStatus;
+import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.equinox.internal.p2.transport.ecf.RepositoryTransport;
import org.eclipse.equinox.p2.tests.testserver.helper.AbstractTestServerClientCase;
@@ -54,7 +61,9 @@ public class FileReaderTest extends AbstractTestServerClientCase {
URI toDownload = new URI(getBaseURL() + "/public/index.html");
final NullProgressMonitor monitor = new NullProgressMonitor();
try (InputStream stream = transport.stream(toDownload, monitor)) {
- //
+ // Avoid unused variable error
+ // https://bugs.eclipse.org/bugs/show_bug.cgi?id=561134
+ stream.toString();
}
assertFalse("1.0", monitor.isCanceled());
}

Back to the top