edu.rice.cs.drjava.model.definitions.indent
Class QuestionStartAfterOpenBraceTest

java.lang.Object
  extended by junit.framework.Assert
      extended by junit.framework.TestCase
          extended by edu.rice.cs.drjava.DrJavaTestCase
              extended by edu.rice.cs.drjava.model.definitions.indent.IndentRulesTestCase
                  extended by edu.rice.cs.drjava.model.definitions.indent.QuestionStartAfterOpenBraceTest
All Implemented Interfaces:
junit.framework.Test

public final class QuestionStartAfterOpenBraceTest
extends IndentRulesTestCase

Tests whether the closest non-whitespace character preceding the start of the current line (excluding any characters inside comments or strings) is an open brace.

Version:
$Id: QuestionStartAfterOpenBraceTest.java 5175 2010-01-20 08:46:32Z mgricken $

Nested Class Summary
 
Nested classes/interfaces inherited from class junit.framework.TestCase
junit.framework.TestCase.WrappedException
 
Field Summary
private  IndentRuleQuestion _rule
           
private  String _text
           
 
Fields inherited from class edu.rice.cs.drjava.model.definitions.indent.IndentRulesTestCase
_doc, TEST_INDENT_LEVEL
 
Constructor Summary
QuestionStartAfterOpenBraceTest()
           
 
Method Summary
 void testBraceLastCharOnLine()
           
 void testCommentsAfterBrace()
           
 void testNoBrace()
           
 void testRightAfterBrace()
           
 void testTextAfterBrace()
           
 void testWSAfterBrace()
           
 
Methods inherited from class edu.rice.cs.drjava.model.definitions.indent.IndentRulesTestCase
_assertContents, _setDocText, setUp, tearDown
 
Methods inherited from class edu.rice.cs.drjava.DrJavaTestCase
setConfigSetting, setDocText
 
Methods inherited from class junit.framework.TestCase
countTestCases, createResult, getName, run, run, runBare, runTest, setName, 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, failNotEquals, failNotSame, failSame, format
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_text

private String _text

_rule

private IndentRuleQuestion _rule
Constructor Detail

QuestionStartAfterOpenBraceTest

public QuestionStartAfterOpenBraceTest()
Method Detail

testNoBrace

public void testNoBrace()
                 throws BadLocationException
Throws:
BadLocationException

testRightAfterBrace

public void testRightAfterBrace()
                         throws BadLocationException
Throws:
BadLocationException

testWSAfterBrace

public void testWSAfterBrace()
                      throws BadLocationException
Throws:
BadLocationException

testCommentsAfterBrace

public void testCommentsAfterBrace()
                            throws BadLocationException
Throws:
BadLocationException

testBraceLastCharOnLine

public void testBraceLastCharOnLine()
                             throws BadLocationException
Throws:
BadLocationException

testTextAfterBrace

public void testTextAfterBrace()
                        throws BadLocationException
Throws:
BadLocationException