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-net.git


The following commit(s) were added to refs/heads/master by this push:
     new 8f0b3719 Use constant
8f0b3719 is described below

commit 8f0b37194f81125d23ed63cebf73bb06f9c1ded5
Author: Gary D. Gregory <[email protected]>
AuthorDate: Sun Aug 24 17:36:45 2025 -0400

    Use constant
---
 src/test/java/org/apache/commons/net/ftp/FTPFileTest.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/test/java/org/apache/commons/net/ftp/FTPFileTest.java 
b/src/test/java/org/apache/commons/net/ftp/FTPFileTest.java
index a503f480..7817dd9d 100644
--- a/src/test/java/org/apache/commons/net/ftp/FTPFileTest.java
+++ b/src/test/java/org/apache/commons/net/ftp/FTPFileTest.java
@@ -30,6 +30,7 @@ import java.time.ZoneId;
 import java.util.Calendar;
 import java.util.TimeZone;
 
+import org.apache.commons.lang3.time.TimeZones;
 import org.junit.jupiter.api.Test;
 
 public class FTPFileTest {
@@ -37,7 +38,7 @@ public class FTPFileTest {
     @Test
     public void testGetTimestampInstant() {
         final FTPFile file = new FTPFile();
-        final Calendar timestamp = 
Calendar.getInstance(TimeZone.getTimeZone("GMT"));
+        final Calendar timestamp = Calendar.getInstance(TimeZones.GMT);
         timestamp.set(2023, Calendar.AUGUST, 4, 23, 40, 55);
         file.setTimestamp(timestamp);
         final Instant timestampInstant = file.getTimestampInstant();

Reply via email to