org.apache.commons.fileupload
Class SizesTest

java.lang.Object
  extended by org.apache.commons.fileupload.FileUploadTestCase
      extended by org.apache.commons.fileupload.SizesTest

public class SizesTest
extends FileUploadTestCase

Unit test for items with varying sizes.

Version:
$Id: SizesTest.java 1458684 2013-03-20 08:31:53Z simonetripodi $

Field Summary
 
Fields inherited from class org.apache.commons.fileupload.FileUploadTestCase
CONTENT_TYPE
 
Constructor Summary
SizesTest()
           
 
Method Summary
 void testFileSizeLimit()
          Checks, whether limiting the file size works.
 void testFileSizeLimitWithFakedContentLength()
          Checks, whether a faked Content-Length header is detected.
 void testFileUpload()
          Runs a test with varying file sizes.
 void testMaxSizeLimit()
          Checks, whether the maxSize works.
 void testMaxSizeLimitUnknownContentLength()
           
 
Methods inherited from class org.apache.commons.fileupload.FileUploadTestCase
parseUpload, parseUpload, parseUpload
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SizesTest

public SizesTest()
Method Detail

testFileUpload

public void testFileUpload()
                    throws IOException,
                           FileUploadException
Runs a test with varying file sizes.

Throws:
IOException
FileUploadException

testFileSizeLimit

public void testFileSizeLimit()
                       throws IOException,
                              FileUploadException
Checks, whether limiting the file size works.

Throws:
IOException
FileUploadException

testFileSizeLimitWithFakedContentLength

public void testFileSizeLimitWithFakedContentLength()
                                             throws IOException,
                                                    FileUploadException
Checks, whether a faked Content-Length header is detected.

Throws:
IOException
FileUploadException

testMaxSizeLimit

public void testMaxSizeLimit()
                      throws IOException,
                             FileUploadException
Checks, whether the maxSize works.

Throws:
IOException
FileUploadException

testMaxSizeLimitUnknownContentLength

public void testMaxSizeLimitUnknownContentLength()
                                          throws IOException,
                                                 FileUploadException
Throws:
IOException
FileUploadException


Copyright © 2002-2013 The Apache Software Foundation. All Rights Reserved.