@Test
public void testBlockUncomment() {

    org.junit.Assume.assumeTrue(!GraphicsEnvironment.isHeadless());
    RSyntaxTextArea scriptPanel = new RSyntaxTextArea();
    scriptPanel.setText("This is a /*test for block*/ uncommenting.");
    // Comment just the first two lines.
    scriptPanel.select(10, 28);
    CommentUtil.blockCommentOrUncomment(scriptPanel);
    assertEquals(10, scriptPanel.getSelectionStart());
    assertEquals(28 - CommentUtil.BLOCK_COMMENT_START.length()
            - CommentUtil.BLOCK_COMMENT_END.length(),
            scriptPanel.getSelectionEnd());
    assertEquals("This is a test for block uncommenting.",
            scriptPanel.getText());
}