org.apache.commons.net.ftp.parser
Class UnixFTPEntryParserTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by org.apache.commons.net.ftp.parser.FTPParseTestFramework
              extended by org.apache.commons.net.ftp.parser.UnixFTPEntryParserTest
All Implemented Interfaces:
junit.framework.Test

public class UnixFTPEntryParserTest
extends FTPParseTestFramework

Version:
$Id: UnixFTPEntryParserTest.java 629276 2008-02-19 23:31:25Z rwinston $
Author:
Steve Cohen

Field Summary
 
Fields inherited from class org.apache.commons.net.ftp.parser.FTPParseTestFramework
df
 
Constructor Summary
UnixFTPEntryParserTest(String name)
           
 
Method Summary
protected  void doAdditionalGoodTests(String test, org.apache.commons.net.ftp.FTPFile f)
          during processing you could hook here to do additional tests
protected  String[] getBadListing()
          Method getBadListing.
protected  String[] getGoodListing()
          Method getGoodListing.
protected  org.apache.commons.net.ftp.FTPFileEntryParser getParser()
          Method getParser.
static junit.framework.TestSuite suite()
          Method suite.
 void testGroupNameWithSpaces()
           
 void testNameWIthPunctuation()
           
 void testNumericDateFormat()
           
 void testOwnerANdGroupNameWithSpaces()
           
 void testOwnerNameWithSpaces()
           
 void testParseFieldsOnDirectory()
          Method testParseFieldsOnDirectory.
 void testParseFieldsOnFile()
          Method testParseFieldsOnFile.
 void testTrailingSpaces()
           
 
Methods inherited from class org.apache.commons.net.ftp.parser.FTPParseTestFramework
doAdditionalBadTests, nullFileOrNullDate, setUp, testBadListing, testGoodListing
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, tearDown, toString
 
Methods inherited from class junit.framework.Assert
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

UnixFTPEntryParserTest

public UnixFTPEntryParserTest(String name)
See Also:
TestCase.TestCase(String)
Method Detail

getBadListing

protected String[] getBadListing()
Description copied from class: FTPParseTestFramework
Method getBadListing. Implementors must provide a listing that contains failures.

Specified by:
getBadListing in class FTPParseTestFramework
Returns:
String[]
See Also:
FTPParseTestFramework.getBadListing()

getGoodListing

protected String[] getGoodListing()
Description copied from class: FTPParseTestFramework
Method getGoodListing. Implementors must provide a listing that passes.

Specified by:
getGoodListing in class FTPParseTestFramework
Returns:
String[]
See Also:
FTPParseTestFramework.getGoodListing()

testNumericDateFormat

public void testNumericDateFormat()

getParser

protected org.apache.commons.net.ftp.FTPFileEntryParser getParser()
Description copied from class: FTPParseTestFramework
Method getParser. Provide the parser to use for testing.

Specified by:
getParser in class FTPParseTestFramework
Returns:
FTPFileEntryParser
See Also:
FTPParseTestFramework.getParser()

testOwnerNameWithSpaces

public void testOwnerNameWithSpaces()

testOwnerANdGroupNameWithSpaces

public void testOwnerANdGroupNameWithSpaces()

testGroupNameWithSpaces

public void testGroupNameWithSpaces()

testTrailingSpaces

public void testTrailingSpaces()

testNameWIthPunctuation

public void testNameWIthPunctuation()

testParseFieldsOnDirectory

public void testParseFieldsOnDirectory()
                                throws Exception
Description copied from class: FTPParseTestFramework
Method testParseFieldsOnDirectory. Provide a test to show that fields on a directory entry are parsed correctly.

Specified by:
testParseFieldsOnDirectory in class FTPParseTestFramework
Throws:
Exception
See Also:
FTPParseTestFramework.testParseFieldsOnDirectory()

testParseFieldsOnFile

public void testParseFieldsOnFile()
                           throws Exception
Description copied from class: FTPParseTestFramework
Method testParseFieldsOnFile. Provide a test to show that fields on a file entry are parsed correctly.

Specified by:
testParseFieldsOnFile in class FTPParseTestFramework
Throws:
Exception
See Also:
FTPParseTestFramework.testParseFieldsOnFile()

suite

public static junit.framework.TestSuite suite()
Method suite.

Returns:
TestSuite

doAdditionalGoodTests

protected void doAdditionalGoodTests(String test,
                                     org.apache.commons.net.ftp.FTPFile f)
Description copied from class: FTPParseTestFramework
during processing you could hook here to do additional tests

Overrides:
doAdditionalGoodTests in class FTPParseTestFramework
Parameters:
test - raw entry
f - parsed entry


Copyright © 1997-2010 Apache Software Foundation. All Rights Reserved.