jmunit.framework.cldc11
Class Assertion

java.lang.Object
  extended by javax.microedition.midlet.MIDlet
      extended by jmunit.framework.cldc11.Assertion
Direct Known Subclasses:
Test

public abstract class Assertion
extends javax.microedition.midlet.MIDlet

The root class for the test classes tree. It has all the basic assertions and main methods used by the developers to create the tests.

Since:
JMUnit 1.0
Author:
Brunno Silva

Constructor Summary
Assertion()
           
 
Method Summary
static void assertEquals(boolean expected, boolean actual)
          Assert if the expected boolean and the actual boolean are equal.
static void assertEquals(byte expected, byte actual)
          Assert if the expected byte and the actual byte are equal.
static void assertEquals(char expected, char actual)
          Assert if the expected char and the actual char are equal.
static void assertEquals(double expected, double actual)
          Assert if the expected double and the actual double are equal.
static void assertEquals(float expected, float actual)
          Assert if the expected float and the actual float are equal.
static void assertEquals(int expected, int actual)
          Assert if the expected int and the actual int are equal.
static void assertEquals(long expected, long actual)
          Assert if the expected long and the actual long are equal.
static void assertEquals(java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object are equal.
static void assertEquals(short expected, short actual)
          Assert if the expected short and the actual short are equal.
static void assertEquals(java.lang.String test, boolean expected, boolean actual)
          Assert if the expected boolean and the actual boolean are equal.
static void assertEquals(java.lang.String test, byte expected, byte actual)
          Assert if the expected byte and the actual byte are equal.
static void assertEquals(java.lang.String test, char expected, char actual)
          Assert if the expected char and the actual char are equal.
static void assertEquals(java.lang.String test, double expected, double actual)
          Assert if the expected double and the actual double are equal.
static void assertEquals(java.lang.String test, float expected, float actual)
          Assert if the expected float and the actual float are equal.
static void assertEquals(java.lang.String test, int expected, int actual)
          Assert if the expected int and the actual int are equal.
static void assertEquals(java.lang.String test, long expected, long actual)
          Assert if the expected long and the actual long are equal.
static void assertEquals(java.lang.String test, java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object are equal.
static void assertEquals(java.lang.String test, short expected, short actual)
          Assert if the expected short and the actual short are equal.
static void assertFalse(boolean expression)
          Assert if the boolean expression is false.
static void assertFalse(java.lang.String test, boolean expression)
          Assert if the boolean expression is false.
static void assertNotEquals(boolean expected, boolean actual)
          Assert if the expected boolean and the actual boolean aren't equal.
static void assertNotEquals(byte expected, byte actual)
          Assert if the expected byte and the actual byte aren't equal.
static void assertNotEquals(char expected, char actual)
          Assert if the expected char and the actual char aren't equal.
static void assertNotEquals(double expected, double actual)
          Assert if the expected double and the actual double aren't equal.
static void assertNotEquals(float expected, float actual)
          Assert if the expected float and the actual float aren't equal.
static void assertNotEquals(int expected, int actual)
          Assert if the expected int and the actual int aren't equal.
static void assertNotEquals(long expected, long actual)
          Assert if the expected long and the actual long aren't equal.
static void assertNotEquals(java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object aren't equal.
static void assertNotEquals(short expected, short actual)
          Assert if the expected short and the actual short aren't equal.
static void assertNotEquals(java.lang.String test, boolean expected, boolean actual)
          Assert if the expected boolean and the actual boolean aren't equal.
static void assertNotEquals(java.lang.String test, byte expected, byte actual)
          Assert if the expected byte and the actual byte aren't equal.
static void assertNotEquals(java.lang.String test, char expected, char actual)
          Assert if the expected char and the actual char aren't equal.
static void assertNotEquals(java.lang.String test, double expected, double actual)
          Assert if the expected double and the actual double aren't equal.
static void assertNotEquals(java.lang.String test, float expected, float actual)
          Assert if the expected float and the actual float aren't equal.
static void assertNotEquals(java.lang.String test, int expected, int actual)
          Assert if the expected int and the actual int aren't equal.
static void assertNotEquals(java.lang.String test, long expected, long actual)
          Assert if the expected long and the actual long aren't equal.
static void assertNotEquals(java.lang.String test, java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object aren't equal.
static void assertNotEquals(java.lang.String test, short expected, short actual)
          Assert if the expected short and the actual short aren't equal.
static void assertNotNull(java.lang.Object object)
          Assert if the object isn't null.
static void assertNotNull(java.lang.String test, java.lang.Object object)
          Assert if the object isn't null.
static void assertNotSame(java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object aren't the same.
static void assertNotSame(java.lang.String test, java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object aren't the same.
static void assertNull(java.lang.Object object)
          Assert if the object is null.
static void assertNull(java.lang.String test, java.lang.Object object)
          Assert if the object is null.
static void assertSame(java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object are the same.
static void assertSame(java.lang.String test, java.lang.Object expected, java.lang.Object actual)
          Assert if the expected object and the actual object are the same.
static void assertTrue(boolean expression)
          Assert if the boolean expression is true.
static void assertTrue(java.lang.String test, boolean expression)
          Assert if the boolean expression is true.
static void fail()
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, boolean expected, boolean actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, byte expected, byte actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, char expected, char actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, double expected, double actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, float expected, float actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, int expected, int actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, long expected, long actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, java.lang.Object expected, java.lang.Object actual)
          This method is used to notify the framework that a assertion failed.
static void fail(java.lang.String test, short expected, short actual)
          This method is used to notify the framework that a assertion failed.
 
Methods inherited from class javax.microedition.midlet.MIDlet
destroyApp, getAppProperty, notifyDestroyed, notifyPaused, pauseApp, resumeRequest, startApp
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Assertion

public Assertion()
Method Detail

assertNull

public static final void assertNull(java.lang.String test,
                                    java.lang.Object object)
                             throws AssertionFailedException
Assert if the object is null. If it is, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
object - the object to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotNull

public static final void assertNotNull(java.lang.String test,
                                       java.lang.Object object)
                                throws AssertionFailedException
Assert if the object isn't null. If it isn't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
object - the object to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertTrue

public static final void assertTrue(java.lang.String test,
                                    boolean expression)
                             throws AssertionFailedException
Assert if the boolean expression is true. If it is, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expression - the boolean expression to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertFalse

public static final void assertFalse(java.lang.String test,
                                     boolean expression)
                              throws AssertionFailedException
Assert if the boolean expression is false. If it is, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expression - the boolean expression to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertSame

public static final void assertSame(java.lang.String test,
                                    java.lang.Object expected,
                                    java.lang.Object actual)
                             throws AssertionFailedException
Assert if the expected object and the actual object are the same. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the object that is correct.
actual - the object that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotSame

public static final void assertNotSame(java.lang.String test,
                                       java.lang.Object expected,
                                       java.lang.Object actual)
                                throws AssertionFailedException
Assert if the expected object and the actual object aren't the same. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the object that is correct.
actual - the object that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      java.lang.Object expected,
                                      java.lang.Object actual)
                               throws AssertionFailedException
Assert if the expected object and the actual object are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the object that is correct.
actual - the object that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         java.lang.Object expected,
                                         java.lang.Object actual)
                                  throws AssertionFailedException
Assert if the expected object and the actual object aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the object that is correct.
actual - the object that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      boolean expected,
                                      boolean actual)
                               throws AssertionFailedException
Assert if the expected boolean and the actual boolean are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the boolean that is correct.
actual - the boolean that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         boolean expected,
                                         boolean actual)
                                  throws AssertionFailedException
Assert if the expected boolean and the actual boolean aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the boolean that is correct.
actual - the boolean that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      char expected,
                                      char actual)
                               throws AssertionFailedException
Assert if the expected char and the actual char are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the char that is correct.
actual - the char that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         char expected,
                                         char actual)
                                  throws AssertionFailedException
Assert if the expected char and the actual char aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the char that is correct.
actual - the char that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      int expected,
                                      int actual)
                               throws AssertionFailedException
Assert if the expected int and the actual int are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the int that is correct.
actual - the int that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         int expected,
                                         int actual)
                                  throws AssertionFailedException
Assert if the expected int and the actual int aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the int that is correct.
actual - the int that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      byte expected,
                                      byte actual)
                               throws AssertionFailedException
Assert if the expected byte and the actual byte are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the byte that is correct.
actual - the byte that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         byte expected,
                                         byte actual)
                                  throws AssertionFailedException
Assert if the expected byte and the actual byte aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the byte that is correct.
actual - the byte that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      long expected,
                                      long actual)
                               throws AssertionFailedException
Assert if the expected long and the actual long are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the long that is correct.
actual - the long that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         long expected,
                                         long actual)
                                  throws AssertionFailedException
Assert if the expected long and the actual long aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the long that is correct.
actual - the long that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      short expected,
                                      short actual)
                               throws AssertionFailedException
Assert if the expected short and the actual short are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the short that is correct.
actual - the short that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      float expected,
                                      float actual)
                               throws AssertionFailedException
Assert if the expected float and the actual float are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the float that is correct.
actual - the float that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         float expected,
                                         float actual)
                                  throws AssertionFailedException
Assert if the expected float and the actual float aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the float that is correct.
actual - the float that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.String test,
                                      double expected,
                                      double actual)
                               throws AssertionFailedException
Assert if the expected double and the actual double are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the double that is correct.
actual - the double that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         double expected,
                                         double actual)
                                  throws AssertionFailedException
Assert if the expected double and the actual double aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the double that is correct.
actual - the double that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.String test,
                                         short expected,
                                         short actual)
                                  throws AssertionFailedException
Assert if the expected short and the actual short aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException.

Parameters:
test - a String used to identify the assert.
expected - the short that is correct.
actual - the short that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNull

public static final void assertNull(java.lang.Object object)
                             throws AssertionFailedException
Assert if the object is null. If it is, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
object - the object to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotNull

public static final void assertNotNull(java.lang.Object object)
                                throws AssertionFailedException
Assert if the object isn't null. If it isn't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
object - the object to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertTrue

public static final void assertTrue(boolean expression)
                             throws AssertionFailedException
Assert if the boolean expression is true. If it is, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expression - the boolean expression to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertFalse

public static final void assertFalse(boolean expression)
                              throws AssertionFailedException
Assert if the boolean expression is false. If it is, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expression - the boolean expression to be tested.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertSame

public static final void assertSame(java.lang.Object expected,
                                    java.lang.Object actual)
                             throws AssertionFailedException
Assert if the expected object and the actual object are the same. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the object that is correct.
actual - the object that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotSame

public static final void assertNotSame(java.lang.Object expected,
                                       java.lang.Object actual)
                                throws AssertionFailedException
Assert if the expected object and the actual object aren't the same. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the object that is correct.
actual - the object that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(java.lang.Object expected,
                                      java.lang.Object actual)
                               throws AssertionFailedException
Assert if the expected object and the actual object are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the object that is correct.
actual - the object that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(java.lang.Object expected,
                                         java.lang.Object actual)
                                  throws AssertionFailedException
Assert if the expected object and the actual object aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the object that is correct.
actual - the object that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(boolean expected,
                                      boolean actual)
                               throws AssertionFailedException
Assert if the expected boolean and the actual boolean are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the boolean that is correct.
actual - the boolean that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(boolean expected,
                                         boolean actual)
                                  throws AssertionFailedException
Assert if the expected boolean and the actual boolean aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the boolean that is correct.
actual - the boolean that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(char expected,
                                      char actual)
                               throws AssertionFailedException
Assert if the expected char and the actual char are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the char that is correct.
actual - the char that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(char expected,
                                         char actual)
                                  throws AssertionFailedException
Assert if the expected char and the actual char aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the char that is correct.
actual - the char that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(int expected,
                                      int actual)
                               throws AssertionFailedException
Assert if the expected int and the actual int are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the int that is correct.
actual - the int that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(int expected,
                                         int actual)
                                  throws AssertionFailedException
Assert if the expected int and the actual int aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the int that is correct.
actual - the int that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(byte expected,
                                      byte actual)
                               throws AssertionFailedException
Assert if the expected byte and the actual byte are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the byte that is correct.
actual - the byte that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(byte expected,
                                         byte actual)
                                  throws AssertionFailedException
Assert if the expected byte and the actual byte aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the byte that is correct.
actual - the byte that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(long expected,
                                      long actual)
                               throws AssertionFailedException
Assert if the expected long and the actual long are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the long that is correct.
actual - the long that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(long expected,
                                         long actual)
                                  throws AssertionFailedException
Assert if the expected long and the actual long aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the long that is correct.
actual - the long that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(short expected,
                                      short actual)
                               throws AssertionFailedException
Assert if the expected short and the actual short are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the short that is correct.
actual - the short that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(short expected,
                                         short actual)
                                  throws AssertionFailedException
Assert if the expected short and the actual short aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the short that is correct.
actual - the short that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(float expected,
                                      float actual)
                               throws AssertionFailedException
Assert if the expected float and the actual float are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the float that is correct.
actual - the float that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(float expected,
                                         float actual)
                                  throws AssertionFailedException
Assert if the expected float and the actual float aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the float that is correct.
actual - the float that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertEquals

public static final void assertEquals(double expected,
                                      double actual)
                               throws AssertionFailedException
Assert if the expected double and the actual double are equal. If they are, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the double that is correct.
actual - the double that should be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

assertNotEquals

public static final void assertNotEquals(double expected,
                                         double actual)
                                  throws AssertionFailedException
Assert if the expected double and the actual double aren't equal. If they aren't, nothing happens. Otherwise, it throws a AssertionFailedException. It has a default String to identify itself.

Parameters:
expected - the double that is correct.
actual - the double that shouldn't be correct.
Throws:
AssertionFailedException - if the assertion fail.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              short expected,
                              short actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              float expected,
                              float actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              double expected,
                              double actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              long expected,
                              long actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              byte expected,
                              byte actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              int expected,
                              int actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              char expected,
                              char actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              boolean expected,
                              boolean actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail(java.lang.String test,
                              java.lang.Object expected,
                              java.lang.Object actual)
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition. It receives some identification parameters, used by the framework in the console fail report.

Parameters:
test - the identification of what failed.
Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0

fail

public static final void fail()
                       throws AssertionFailedException
This method is used to notify the framework that a assertion failed. It also may be used by the developers to produce a fail in some special condition.

Throws:
AssertionFailedException - as result of a failed assertion.
Since:
JMUnit 1.0