package test;

import junit.framework.Assert;

import org.junit.Test;

import vash.OutputParameters;

public class TestOutputParameters {
	private OutputParameters op;
	
    
	@Test
	public void testGetFilename() {
		op = new vash.OutputParameters("foo.png", 64, 64);
		Assert.assertTrue(op.getFilename().equals("foo.png"));
		op = new vash.OutputParameters("-", 64, 64);
		Assert.assertTrue(op.getFilename().equals("-"));
	}

	@Test(expected=IllegalArgumentException.class)
	public void testGetFilenameFail() {
		op = new vash.OutputParameters("foo.bar", 64, 64);
	}
	
	@Test
	public void testGetImageType() {
		op = new vash.OutputParameters("foo.png", 64, 64);
		Assert.assertTrue(op.getImageType().equals("png"));
		op = new vash.OutputParameters("foo.bmp", 64, 64);
		Assert.assertTrue(op.getImageType().equals("bmp"));
		op = new vash.OutputParameters("foo.jpg", 64, 64);
		Assert.assertTrue(op.getImageType().equals("jpeg"));
		op = new vash.OutputParameters("-", 64, 64);
		Assert.assertTrue(op.getImageType().equals("png"));
	}

	@Test
	public void testGetWidth() {
		op = new vash.OutputParameters("foo.png", 42, 64);
		Assert.assertTrue(op.getWidth() == 42);
	}

	@Test
	public void testGetHeight() {
		op = new vash.OutputParameters("foo.png", 64, 42);
		Assert.assertTrue(op.getHeight() == 42);
	}
}

@@ -280,46 +280,41 @@
 sert
-True(op.getFilename().equals(%22foo.png%22
+Equals(%22foo.png%22, op.getFilename(
 ));%0A
@@ -371,29 +371,36 @@
 ssert.assert
-True(
+Equals(%22-%22, 
 op.getFilena
@@ -407,20 +407,8 @@
 me()
-.equals(%22-%22)
 );%0A%09
@@ -654,37 +654,46 @@
 %0A%09%09Assert.assert
-True(
+Equals(%22png%22, 
 op.getImageType(
@@ -689,38 +689,24 @@
 tImageType()
-.equals(%22png%22)
 );%0A%09%09op = ne
@@ -756,37 +756,46 @@
 %0A%09%09Assert.assert
-True(
+Equals(%22bmp%22, 
 op.getImageType(
@@ -799,22 +799,8 @@
 pe()
-.equals(%22bmp%22)
 );%0A%09
@@ -858,37 +858,47 @@
 %0A%09%09Assert.assert
-True(
+Equals(%22jpeg%22, 
 op.getImageType(
@@ -902,23 +902,8 @@
 pe()
-.equals(%22jpeg%22)
 );%0A%09
@@ -959,29 +959,38 @@
 ssert.assert
-True(
+Equals(%22png%22, 
 op.getImageT
@@ -998,22 +998,8 @@
 pe()
-.equals(%22png%22)
 );%0A%09
@@ -1102,29 +1102,35 @@
 ssert.assert
-True(
+Equals(42, 
 op.getWidth(
@@ -1130,22 +1130,16 @@
 tWidth()
- == 42
 );%0A%09%7D%0A%0A%09
@@ -1247,13 +1247,19 @@
 sert
-True(
+Equals(42, 
 op.g
@@ -1272,14 +1272,8 @@
 ht()
- == 42
 );%0A%09

use the more correct assertEquals here