@Test
public void testReplaceText() {

    // Complex string test.  Make sure that characters are not lost.
    String test = "a&3test.";
    EnhancedString cs = new ColoredString(test);
    EnhancedString result = cs.replaceText(Pattern.compile("test"), "derp&4");
    assertEquals(result.getRaw(), "a&3derp&4.");
}