Merge branch 'master' of https://gitbox.apache.org/repos/asf/commons-vfs
diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTest.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTestCase.java
similarity index 98%
rename from commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTest.java
rename to commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTestCase.java
index 0530e42..31ea9b5 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTest.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5GetContentInfoTestCase.java
@@ -34,7 +34,7 @@
/**
* Tests VFS-427 NPE on Http5FileObject.getContent().getContentInfo().
*/
-public class Http5GetContentInfoTest extends TestCase {
+public class Http5GetContentInfoTestCase extends TestCase {
FileSystemOptions getOptionsWithProxy() throws MalformedURLException {
// get proxy host and port from env var "https_proxy"
diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5ProviderTestCase.java b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5ProviderTestCase.java
index 4313cb7..e58a6f7 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5ProviderTestCase.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http5/Http5ProviderTestCase.java
@@ -124,6 +124,13 @@
return manager.resolveFile(uri);
}
+ // Test no longer passing 2016/04/28
+ public void ignoreTestHttp405() throws FileSystemException {
+ final FileObject fileObject = VFS.getManager()
+ .resolveFile("http5://www.w3schools.com/webservices/tempconvert.asmx?action=WSDL");
+ assert !fileObject.getContent().isEmpty();
+ }
+
/**
* Prepares the file system manager.
*/
@@ -134,6 +141,27 @@
}
}
+ /** Ensure VFS-453 options are present. */
+ public void testHttpTimeoutConfig() {
+ final FileSystemOptions opts = new FileSystemOptions();
+ final Http5FileSystemConfigBuilder builder = Http5FileSystemConfigBuilder.getInstance();
+
+ // ensure defaults are 0
+ assertEquals(0, builder.getConnectionTimeout(opts));
+ assertEquals(0, builder.getSoTimeout(opts));
+ assertEquals("Jakarta-Commons-VFS", builder.getUserAgent(opts));
+
+ builder.setConnectionTimeout(opts, 60000);
+ builder.setSoTimeout(opts, 60000);
+ builder.setUserAgent(opts, "foo/bar");
+
+ // ensure changes are visible
+ assertEquals(60000, builder.getConnectionTimeout(opts));
+ assertEquals(60000, builder.getSoTimeout(opts));
+ assertEquals("foo/bar", builder.getUserAgent(opts));
+
+ }
+
private void testResloveFolderSlash(final String uri, final boolean followRedirect) throws FileSystemException {
VFS.getManager().getFilesCache().close();
final FileSystemOptions opts = new FileSystemOptions();
@@ -161,32 +189,4 @@
public void testResloveFolderSlashYesRedirectOn() throws FileSystemException {
testResloveFolderSlash(ConnectionUri + "/read-tests/", true);
}
-
- // Test no longer passing 2016/04/28
- public void ignoreTestHttp405() throws FileSystemException {
- final FileObject fileObject = VFS.getManager()
- .resolveFile("http5://www.w3schools.com/webservices/tempconvert.asmx?action=WSDL");
- assert !fileObject.getContent().isEmpty();
- }
-
- /** Ensure VFS-453 options are present. */
- public void testHttpTimeoutConfig() {
- final FileSystemOptions opts = new FileSystemOptions();
- final Http5FileSystemConfigBuilder builder = Http5FileSystemConfigBuilder.getInstance();
-
- // ensure defaults are 0
- assertEquals(0, builder.getConnectionTimeout(opts));
- assertEquals(0, builder.getSoTimeout(opts));
- assertEquals("Jakarta-Commons-VFS", builder.getUserAgent(opts));
-
- builder.setConnectionTimeout(opts, 60000);
- builder.setSoTimeout(opts, 60000);
- builder.setUserAgent(opts, "foo/bar");
-
- // ensure changes are visible
- assertEquals(60000, builder.getConnectionTimeout(opts));
- assertEquals(60000, builder.getSoTimeout(opts));
- assertEquals("foo/bar", builder.getUserAgent(opts));
-
- }
}
diff --git a/src/changes/changes.xml b/src/changes/changes.xml
index cabb28d..89bb0bd 100644
--- a/src/changes/changes.xml
+++ b/src/changes/changes.xml
@@ -120,7 +120,7 @@
Update commons.japicmp.version 0.14.3 -> 0.15.2.
</action>
<action dev="ggregory" due-to="Arturo Bernal" type="update">
- Minor Improvements, #152, #156.
+ Minor Improvements, #152, #156, #160.
</action>
<action dev="ggregory" due-to="Gary Gregory" type="update">
Update commons.spotbugs.impl.version 4.1.3 -> 4.2.0.