You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by se...@apache.org on 2008/03/12 20:45:37 UTC
svn commit: r636477 -
/commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java
Author: sebb
Date: Wed Mar 12 12:45:35 2008
New Revision: 636477
URL: http://svn.apache.org/viewvc?rev=636477&view=rev
Log:
Disable future-dated tests until it has been decided how to handle +6 months dates
Modified:
commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java
Modified: commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java
URL: http://svn.apache.org/viewvc/commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java?rev=636477&r1=636476&r2=636477&view=diff
==============================================================================
--- commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java (original)
+++ commons/proper/net/branches/NET_2_0/src/test/java/org/apache/commons/net/ftp/parser/FTPTimestampParserImplTest.java Wed Mar 12 12:45:35 2008
@@ -271,29 +271,31 @@
checkShortParse("2004-8-1 -26 weeks",now,target);
}
- public void testParseShortFutureDates1() throws Exception {
- GregorianCalendar now = new GregorianCalendar(2001, Calendar.MAY, 30, 12, 0);
- checkShortParse("2001-5-30",now,now); // should always work
- GregorianCalendar target = (GregorianCalendar) now.clone();
- target.add(Calendar.WEEK_OF_YEAR, 1);
- checkShortParse("2001-5-30 +1 week",now,target);
- target.add(Calendar.WEEK_OF_YEAR, 12);
- checkShortParse("2001-5-30 +13 weeks",now,target);
- target.add(Calendar.WEEK_OF_YEAR, 13);
- checkShortParse("2001-5-30 +26 weeks",now,target);
- }
+// It has not yet been decided how to handle future dates, so skip these tests for now
+
+// public void testParseShortFutureDates1() throws Exception {
+// GregorianCalendar now = new GregorianCalendar(2001, Calendar.MAY, 30, 12, 0);
+// checkShortParse("2001-5-30",now,now); // should always work
+// GregorianCalendar target = (GregorianCalendar) now.clone();
+// target.add(Calendar.WEEK_OF_YEAR, 1);
+// checkShortParse("2001-5-30 +1 week",now,target);
+// target.add(Calendar.WEEK_OF_YEAR, 12);
+// checkShortParse("2001-5-30 +13 weeks",now,target);
+// target.add(Calendar.WEEK_OF_YEAR, 13);
+// checkShortParse("2001-5-30 +26 weeks",now,target);
+// }
- public void testParseShortFutureDates2() throws Exception {
- GregorianCalendar now = new GregorianCalendar(2004, Calendar.AUGUST, 1, 12, 0);
- checkShortParse("2004-8-1",now,now); // should always work
- GregorianCalendar target = (GregorianCalendar) now.clone();
- target.add(Calendar.WEEK_OF_YEAR, 1);
- checkShortParse("2004-8-1 +1 week",now,target);
- target.add(Calendar.WEEK_OF_YEAR, 12);
- checkShortParse("2004-8-1 +13 weeks",now,target);
- target.add(Calendar.WEEK_OF_YEAR, 13);
- checkShortParse("2004-8-1 +26 weeks",now,target);
- }
+// public void testParseShortFutureDates2() throws Exception {
+// GregorianCalendar now = new GregorianCalendar(2004, Calendar.AUGUST, 1, 12, 0);
+// checkShortParse("2004-8-1",now,now); // should always work
+// GregorianCalendar target = (GregorianCalendar) now.clone();
+// target.add(Calendar.WEEK_OF_YEAR, 1);
+// checkShortParse("2004-8-1 +1 week",now,target);
+// target.add(Calendar.WEEK_OF_YEAR, 12);
+// checkShortParse("2004-8-1 +13 weeks",now,target);
+// target.add(Calendar.WEEK_OF_YEAR, 13);
+// checkShortParse("2004-8-1 +26 weeks",now,target);
+// }
// Test leap year if current year is a leap year
public void testFeb29IfLeapYear() throws Exception{