edu.rice.cs.drjava.model
Class GlobalModelJUnitTest
java.lang.Object
|
+--junit.framework.Assert
|
+--junit.framework.TestCase
|
+--edu.rice.cs.drjava.model.GlobalModelTestCase
|
+--edu.rice.cs.drjava.model.GlobalModelJUnitTest
- All Implemented Interfaces:
- Test
- public class GlobalModelJUnitTest
- extends GlobalModelTestCase
A test on the GlobalModel for JUnit testing.
- Version:
- $Id: GlobalModelJUnitTest.java,v 1.14 2002/09/13 22:55:34 csreis Exp $
Fields inherited from class edu.rice.cs.drjava.model.GlobalModelTestCase |
_model, _originalModel, _tempDir, BAR_TEXT, BAZ_TEXT, FOO_MISSING_CLOSE_TEXT, FOO_PACKAGE_AFTER_IMPORT, FOO_PACKAGE_AS_FIELD, FOO_PACKAGE_AS_FIELD_2, FOO_PACKAGE_AS_PART_OF_FIELD, FOO_PACKAGE_INSIDE_CLASS, FOO_TEXT |
Methods inherited from class edu.rice.cs.drjava.model.GlobalModelTestCase |
assertCompileErrorsPresent, assertCompileErrorsPresent, assertContents, assertLength, assertModified, assertNumOpenDocs, changeDocumentText, classForJava, createFile, createModel, interpret, interpretIgnoreResult, setUp, setupDocument, tearDown, tempDirectory, tempFile, tempFile, writeToNewTempFile |
Methods inherited from class junit.framework.Assert |
assert, assert, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertNotNull, assertNotNull, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame |
Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, wait, wait, wait |
MONKEYTEST_PASS_TEXT
private static final String MONKEYTEST_PASS_TEXT
MONKEYTEST_FAIL_TEXT
private static final String MONKEYTEST_FAIL_TEXT
MONKEYTEST_COMPILEERROR_TEXT
private static final String MONKEYTEST_COMPILEERROR_TEXT
NONPUBLIC_TEXT
private static final String NONPUBLIC_TEXT
NON_TESTCASE_TEXT
private static final String NON_TESTCASE_TEXT
MONKEYTEST_INFINITE_TEXT
private static final String MONKEYTEST_INFINITE_TEXT
GlobalModelJUnitTest
public GlobalModelJUnitTest(String name)
- Constructor.
- Parameters:
String
- name
suite
public static Test suite()
- Creates a test suite for JUnit to run.
- Returns:
- a test suite based on the methods in this class
testNoJUnitErrors
public void testNoJUnitErrors()
throws Exception
- Tests that a JUnit file with no errors is reported to have no errors.
testOneJUnitError
public void testOneJUnitError()
throws Exception
- Tests that a JUnit file with an error is reported to have an error.
testNonTestCaseError
public void testNonTestCaseError()
throws Exception
- Tests that the ui is notified to put up an error dialog if JUnit
is run on a non-TestCase.
testResultOfNonPublicTestCase
public void testResultOfNonPublicTestCase()
throws Exception
- Tests that the ui is notified to put up an error dialog if JUnit
is run on a non-public TestCase.
testDoNotRunJUnitIfFileHasBeenMoved
public void testDoNotRunJUnitIfFileHasBeenMoved()
throws Exception
testNoClassFile
public void testNoClassFile()
throws Exception
- Tests a document that has no corresponding class file.
testInfiniteLoop
public void testInfiniteLoop()
throws Exception
- Tests that an infinite loop in a test case can be aborted by clicking
the Reset button.
testUnsavedAndUnCompiledChanges
public void testUnsavedAndUnCompiledChanges()
throws Exception
- Tests that when a JUnit file with no errors, after being saved and compiled,
has it's contents replaced by a test that should fail, will pass all tests.