Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

nice.tools.testsuite
Class FailTestCase  view FailTestCase download FailTestCase.java

java.lang.Object
  extended bynice.tools.testsuite.TestCase
      extended bynice.tools.testsuite.FailTestCase

public class FailTestCase
extends TestCase

TestCase class for test cases that should fail.

Version:
$Id: FailTestCase.java,v 1.12 2003/02/19 18:30:29 bonniot Exp $

Nested Class Summary
 
Nested classes inherited from class nice.tools.testsuite.TestCase
TestCase.FailPosition
 
Field Summary
 
Fields inherited from class nice.tools.testsuite.TestCase
isKnownBug, skip
 
Constructor Summary
FailTestCase(TestSuite suite)
          Constructor.
 
Method Summary
private  void checkFailPositions()
          Parses the compiler messages for line, column, filename and compares them with the expected failure positions that the user defined.
 void performTest()
          Performs the test for this testcase.
 
Methods inherited from class nice.tools.testsuite.TestCase
compilePackages, consumeLine, fail, getCompilerMessages, getFailPositions, pass, runMain, warning, writeFiles
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FailTestCase

public FailTestCase(TestSuite suite)
Constructor.

Method Detail

performTest

public void performTest()
Performs the test for this testcase. Compilation should fail, otherwise throw exception.

Overrides:
performTest in class TestCase

checkFailPositions

private void checkFailPositions()
Parses the compiler messages for line, column, filename and compares them with the expected failure positions that the user defined. If the user defined more expected failure positions than the compiler recognized then a warning is shown. A warning is also shown when the user expected a failure at another position than the compiler recognized.