summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Moir2012-02-05 13:34:44 (EST)
committerKim Moir2012-02-05 13:34:44 (EST)
commit78942201284c85d2b95ee73cb689a76e91f0d567 (patch)
treefb047dc31b21286de0bb47c6fd2c6df726a83eba
parent16561535fe8dec939f658196392fe9e0e7658ce3 (diff)
downloadeclipse.platform.ua-78942201284c85d2b95ee73cb689a76e91f0d567.zip
eclipse.platform.ua-78942201284c85d2b95ee73cb689a76e91f0d567.tar.gz
eclipse.platform.ua-78942201284c85d2b95ee73cb689a76e91f0d567.tar.bz2
Bug 369828 - Test failures on JRE 7
-rw-r--r--org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webapp/TocZipTest.java15
1 files changed, 6 insertions, 9 deletions
diff --git a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webapp/TocZipTest.java b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webapp/TocZipTest.java
index ad6ef36..dee42d4 100644
--- a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webapp/TocZipTest.java
+++ b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/webapp/TocZipTest.java
@@ -34,16 +34,16 @@ public class TocZipTest extends TestCase {
}
public void testDocInZipOnly() throws IOException {
- final String path = "/org.eclipse.ua.tests/data/help/manual/dz1.html";
- String contents = readPage(path);
- assertTrue(contents.indexOf("dz1 from doc.zip") > -1);
+ final String path= "/org.eclipse.ua.tests/data/help/manual/dz1.html";
+ String contents= readPage(path);
+ assertTrue(contents.indexOf("dz1 from doc.zip") > -1);
}
-
+
/**
* Verify that loose files override those in doc.zip
* @throws IOException
*/
- public void testXXXDocInZipAndBundle() throws IOException {
+ public void testDocInZipAndBundle() throws IOException {
final String path = "/org.eclipse.ua.tests/data/help/manual/dz2.html";
String contents = readPage(path);
assertFalse(contents.indexOf("dz2 from doc.zip") > -1);
@@ -54,10 +54,7 @@ public class TocZipTest extends TestCase {
IOException {
int port = WebappManager.getPort();
URL url = new URL("http", "localhost", port, "/help/topic" + path);
- URLConnection connection= url.openConnection();
- connection.setConnectTimeout(5000);
- connection.setReadTimeout(5000);
- InputStream is= connection.getInputStream();
+ InputStream is = url.openStream();
BufferedInputStream buffered = new BufferedInputStream(is);
ByteArrayOutputStream os = new ByteArrayOutputStream();
int result = buffered.read();