This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-vfs.git
The following commit(s) were added to refs/heads/master by this push:
new f51ae0e6 Fix some Checkstyle issues
f51ae0e6 is described below
commit f51ae0e627fb49db19883d8ea36de01877612afc
Author: Gary Gregory <[email protected]>
AuthorDate: Wed Oct 11 11:42:29 2023 -0400
Fix some Checkstyle issues
---
checkstyle-suppressions.xml | 7 ++++++-
.../java/org/apache/commons/vfs2/AbstractProviderTestCase.java | 2 +-
.../src/test/java/org/apache/commons/vfs2/ContentTests.java | 4 ++--
.../src/test/java/org/apache/commons/vfs2/FileInfo.java | 2 +-
.../src/test/java/org/apache/commons/vfs2/NamingTests.java | 2 +-
.../java/org/apache/commons/vfs2/PatternFileSelectorTest.java | 6 +++---
.../test/java/org/apache/commons/vfs2/PermissionsTests.java | 4 ++--
.../vfs2/provider/ftps/AbstractFtpsProviderTestCase.java | 10 +++++-----
.../apache/commons/vfs2/provider/http/HttpFilesCacheTest.java | 5 ++---
.../vfs2/provider/http/HttpGetContentInfoFunctionalTest.java | 2 +-
10 files changed, 24 insertions(+), 20 deletions(-)
diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml
index ab659016..80d759a3 100644
--- a/checkstyle-suppressions.xml
+++ b/checkstyle-suppressions.xml
@@ -24,7 +24,12 @@
<!-- Exceptions for Checkstyle -->
<suppressions>
-
+ <!-- Disable some checks in tests -->
+ <suppress checks="JavadocPackage" files="src[/\\]test[/\\]java[/\\]" />
+ <suppress checks="JavadocMethod" files="src[/\\]test[/\\]java[/\\]" />
+ <suppress checks="JavadocVariable" files="src[/\\]test[/\\]java[/\\]" />
+ <suppress checks="MissingJavadocMethod" files="src[/\\]test[/\\]java[/\\]"
/>
+
<!-- Disable the warnings for the generated classes -->
<suppress checks=".*" files="ParseException.java"/>
<suppress checks=".*" files="PropertyListParser.java"/>
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/AbstractProviderTestCase.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/AbstractProviderTestCase.java
index fefc5ff0..0de55f5c 100644
---
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/AbstractProviderTestCase.java
+++
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/AbstractProviderTestCase.java
@@ -240,7 +240,7 @@ public abstract class AbstractProviderTestCase extends
TestCase {
}
/**
- * get the provider configuration
+ * get the provider configuration.
*/
public ProviderTestConfig getProviderConfig() {
return providerConfig;
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/ContentTests.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/ContentTests.java
index 6dceb7ca..5ec7b9af 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/ContentTests.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/ContentTests.java
@@ -57,7 +57,7 @@ public class ContentTests extends AbstractProviderTestCase {
}
/**
- * Tests attributes
+ * Tests attributes.
*/
@Test
public void testAttributes() throws FileSystemException {
@@ -237,7 +237,7 @@ public class ContentTests extends AbstractProviderTestCase {
}
/**
- * Tests parent identity
+ * Tests parent identity.
*/
@Test
public void testParent() throws FileSystemException {
diff --git a/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileInfo.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileInfo.java
index 0a8426a2..b8418175 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileInfo.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/FileInfo.java
@@ -99,7 +99,7 @@ public class FileInfo {
}
/**
- * Returns the {@link FileType} of the file
+ * Returns the {@link FileType} of the file.
*
* @return {@link FileType}
*/
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/NamingTests.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/NamingTests.java
index 03d3ccbb..69df17b4 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/NamingTests.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/NamingTests.java
@@ -307,7 +307,7 @@ public class NamingTests extends AbstractProviderTestCase {
}
/**
- * Tests resolution of relative file names via the FS manager
+ * Tests resolution of relative file names via the FS manager.
*/
@Test
public void testRelativeURI() throws Exception {
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/PatternFileSelectorTest.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/PatternFileSelectorTest.java
index 91de2260..3c2730d0 100644
---
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/PatternFileSelectorTest.java
+++
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/PatternFileSelectorTest.java
@@ -116,7 +116,7 @@ public class PatternFileSelectorTest {
}
/**
- * Tests matching all
+ * Tests matching all.
*
* @throws Exception
*/
@@ -127,7 +127,7 @@ public class PatternFileSelectorTest {
}
/**
- * Tests matching partial file names
+ * Tests matching partial file names.
*
* @throws Exception
*/
@@ -139,7 +139,7 @@ public class PatternFileSelectorTest {
}
/**
- * Tests matching partial file names with delimiter
+ * Tests matching partial file names with delimiter.
*
* @throws Exception
*/
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/PermissionsTests.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/PermissionsTests.java
index f03b2798..b2810028 100644
--- a/commons-vfs2/src/test/java/org/apache/commons/vfs2/PermissionsTests.java
+++ b/commons-vfs2/src/test/java/org/apache/commons/vfs2/PermissionsTests.java
@@ -113,7 +113,7 @@ public class PermissionsTests extends
AbstractProviderTestCase {
}
/**
- * Tests for the readable permission
+ * Tests for the readable permission.
*/
@Test
public void testReadable() throws Exception {
@@ -138,7 +138,7 @@ public class PermissionsTests extends
AbstractProviderTestCase {
}
/**
- * Tests for the writable permission
+ * Tests for the writable permission.
*/
@Test
public void testWriteable() throws Exception {
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/ftps/AbstractFtpsProviderTestCase.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/ftps/AbstractFtpsProviderTestCase.java
index bd402c4e..ad8e8de5 100644
---
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/ftps/AbstractFtpsProviderTestCase.java
+++
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/ftps/AbstractFtpsProviderTestCase.java
@@ -100,7 +100,7 @@ abstract class AbstractFtpsProviderTestCase extends
AbstractProviderTestConfig {
}
static int getSocketPort() {
- return SocketPort;
+ return socketPort;
}
static String getSystemTestUriOverride() {
@@ -118,7 +118,7 @@ abstract class AbstractFtpsProviderTestCase extends
AbstractProviderTestConfig {
return;
}
// Let the OS find use an ephemeral port by using 0.
- SocketPort = 0;
+ socketPort = 0;
final FtpServerFactory serverFactory = new FtpServerFactory();
final PropertiesUserManagerFactory propertiesUserManagerFactory = new
PropertiesUserManagerFactory();
final URL userPropsResource =
ClassLoader.getSystemClassLoader().getResource(USER_PROPS_RES);
@@ -131,7 +131,7 @@ abstract class AbstractFtpsProviderTestCase extends
AbstractProviderTestConfig {
user.setHomeDirectory(getTestDirectory());
serverFactory.setUserManager(userManager);
final ListenerFactory listenerFactory = new ListenerFactory();
- listenerFactory.setPort(SocketPort);
+ listenerFactory.setPort(socketPort);
// define SSL configuration
final URL serverJksResource =
ClassLoader.getSystemClassLoader().getResource(SERVER_JKS_RES);
@@ -163,9 +163,9 @@ abstract class AbstractFtpsProviderTestCase extends
AbstractProviderTestConfig {
e.printStackTrace();
}
}
- SocketPort = ((org.apache.ftpserver.impl.DefaultFtpServer)
embeddedFtpServer).getListener(LISTENER_NAME).getPort();
+ socketPort = ((org.apache.ftpserver.impl.DefaultFtpServer)
embeddedFtpServer).getListener(LISTENER_NAME).getPort();
// System.out.println("Using port " + SocketPort);
- connectionUri = "ftps://test:test@localhost:" + SocketPort;
+ connectionUri = "ftps://test:test@localhost:" + socketPort;
}
/**
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpFilesCacheTest.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpFilesCacheTest.java
index 7d0aaf9e..fe1eb602 100644
---
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpFilesCacheTest.java
+++
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpFilesCacheTest.java
@@ -25,15 +25,14 @@ import org.apache.commons.vfs2.VFS;
import org.junit.jupiter.api.Test;
/**
- * Tests https://issues.apache.org/jira/browse/VFS-426
+ * Tests https://issues.apache.org/jira/browse/VFS-426.
*
- * ggregory $
* @since 2.1
*/
public class HttpFilesCacheTest {
/**
- * Tests https://issues.apache.org/jira/browse/VFS-426
+ * Tests https://issues.apache.org/jira/browse/VFS-426.
*/
@Test
public void testQueryStringUrls() throws FileSystemException {
diff --git
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpGetContentInfoFunctionalTest.java
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpGetContentInfoFunctionalTest.java
index 8f433179..babd977f 100644
---
a/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpGetContentInfoFunctionalTest.java
+++
b/commons-vfs2/src/test/java/org/apache/commons/vfs2/provider/http/HttpGetContentInfoFunctionalTest.java
@@ -30,7 +30,7 @@ import org.apache.commons.vfs2.VFS;
import org.junit.jupiter.api.Test;
/**
- * Tests VFS-427 NPE on HttpFileObject.getContent().getContentInfo()
+ * Tests VFS-427 NPE on HttpFileObject.getContent().getContentInfo().
*
* @since 2.1
*/