us.zuercher.gpx2map.image.generic.test
Class GenericImageTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by us.zuercher.gpx2map.image.generic.test.GenericImageTest
All Implemented Interfaces:
Test

public class GenericImageTest
extends TestCase

GenericImageTest tests GenericImage and GenericImageFactory.

Author:
Stephan Zuercher

Constructor Summary
GenericImageTest(String name)
          Constructs a new GenericImageTest with the given name.
 
Method Summary
 void testGif()
          Test a GIF file with a non-trivial transparency data.
 void testGifNoAlpha()
          Test a GIF file with no transparency.
 void testJpeg()
          Test a JPEG file.
 void testPng()
          Test a PNG file with a non-trivial transparency data.
 void testPngNoAlpha()
          Test a PNG file with no transparency.
 void testUnknownFormat()
          Tests that a PPM file throws UnknownFormatException.
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, 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
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GenericImageTest

public GenericImageTest(String name)
Constructs a new GenericImageTest with the given name.

Parameters:
name - test name
Method Detail

testGif

public void testGif()
             throws IOException
Test a GIF file with a non-trivial transparency data.

Throws:
IOException - if GenericImageFactory does

testPng

public void testPng()
             throws IOException
Test a PNG file with a non-trivial transparency data.

Throws:
IOException - if GenericImageFactory does

testGifNoAlpha

public void testGifNoAlpha()
                    throws IOException
Test a GIF file with no transparency.

Throws:
IOException - if GenericImageFactory does

testPngNoAlpha

public void testPngNoAlpha()
                    throws IOException
Test a PNG file with no transparency.

Throws:
IOException - if GenericImageFactory does

testJpeg

public void testJpeg()
              throws IOException
Test a JPEG file.

Throws:
IOException - if GenericImageFactory does

testUnknownFormat

public void testUnknownFormat()
                       throws IOException
Tests that a PPM file throws UnknownFormatException.

Throws:
IOException - if GenericImageFactory does