edu.rice.cs.drjava.model.definitions.indent
Class QuestionStartingNewStmtTest
java.lang.Object
|
+--junit.framework.Assert
|
+--junit.framework.TestCase
|
+--edu.rice.cs.drjava.model.definitions.indent.IndentRulesTestCase
|
+--edu.rice.cs.drjava.model.definitions.indent.QuestionStartingNewStmtTest
- All Implemented Interfaces:
- Test
- public class QuestionStartingNewStmtTest
- extends IndentRulesTestCase
Tests the question rule which determines if the current line
is starting a new statement.
- Version:
- $Id: QuestionStartingNewStmtTest.java,v 1.2 2002/03/27 21:50:24 besan Exp $
Methods inherited from class junit.framework.TestCase |
countTestCases, createResult, getName, name, run, run, runBare, runTest, setName, tearDown, toString |
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 |
QuestionStartingNewStmtTest
public QuestionStartingNewStmtTest(String name)
- Tests the indentation decision tree.
testStartOfStmtCheckForEndCharacters
public void testStartOfStmtCheckForEndCharacters()
throws BadLocationException
- Ensures that the current line is the first line of a statement.
This is done by testing if the previous character is one of
the following: docstart, ';', '{', '}'
These characters are here-on refered to as 'end-characters'.
testStartOfStmtIgnoreWhiteSpaceAndCommentsInBetween
public void testStartOfStmtIgnoreWhiteSpaceAndCommentsInBetween()
throws BadLocationException
- Ensures that the current line is the first line of a statement.
Tests that whitespace, single-line and multi-line comments
are ignored when searching for the end-characters.
testNotStartOfStmtDueToEndCharactersInCommentsOrQuotes
public void testNotStartOfStmtDueToEndCharactersInCommentsOrQuotes()
throws BadLocationException
- Ensures that the current line is the first line of a statement.
Tests that end characters in single-line comments, multi-line
comments or quotes are ignored.