JML

org.multijava.util.testing
Class TestCase

java.lang.Object
  extended byjunit.framework.Assert
      extended byjunit.framework.TestCase
          extended byorg.multijava.util.testing.TestCase
All Implemented Interfaces:
junit.framework.Test
Direct Known Subclasses:
FileCompareTestCase, FunctionalTestSuite.TestCase, SampleTestCase, TestArrayListCache, TestCContext, TestDirectedAcyclicGraph, TestFilesCompileAllRunEachTestSuite.CompileTestCase, TestFilesCompileAllRunEachTestSuite.RunTestCase, TestFilesTestSuite.Helper, TestIntStack, TestJavadocComment, TestJmlParser, TestJTypeDeclaration, TestLexgenLexer, TestMain, TestMjcParser, TestParsingController

public class TestCase
extends junit.framework.TestCase

Some utility methods for test cases


Field Summary
protected static String NEWLINE
           
 
Fields inherited from class junit.framework.TestCase
 
Constructor Summary
TestCase(String name)
           
 
Method Summary
protected  void assertDiff(String expected, String actual)
           
protected  void assertEquals(String expected, String actual, boolean detailed)
          Compare Strings for equality with better difference reporting.
 
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
 

Field Detail

NEWLINE

protected static final String NEWLINE
Constructor Detail

TestCase

public TestCase(String name)
Method Detail

assertEquals

protected void assertEquals(String expected,
                            String actual,
                            boolean detailed)
Compare Strings for equality with better difference reporting.

Parameters:
expected - the expected string
actual - the actual string
detailed - if true then report first position of difference along with Unicode values of the two characters, otherwise just compare strings for equality

assertDiff

protected void assertDiff(String expected,
                          String actual)

JML

JML is Copyright (C) 1998-2002 by Iowa State University and is distributed under the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This release depends on code from the MultiJava project and is based in part on the Kopi project Copyright (C) 1990-99 DMS Decision Management Systems Ges.m.b.H.