use of com.bergerkiller.bukkit.common.wrappers.ChatText in project BKCommonLib by bergerhealer.
the class ChatTextTest method testSuffixStyle.
@Test
public void testSuffixStyle() {
// Test that a String with a suffix chat style character preserves the style
String msg = "Prefix" + ChatColor.RED.toString();
ChatText text = ChatText.fromMessage(msg);
assertEquals(msg, text.getMessage());
}
use of com.bergerkiller.bukkit.common.wrappers.ChatText in project BKCommonLib by bergerhealer.
the class ChatTextTest method testPrefixStyle.
@Test
public void testPrefixStyle() {
// Test that a String with a prefix chat style character preserves the style
String msg = ChatColor.RED.toString() + "Postfix";
ChatText text = ChatText.fromMessage(msg);
assertEquals(msg, text.getMessage());
}
use of com.bergerkiller.bukkit.common.wrappers.ChatText in project BKCommonLib by bergerhealer.
the class ChatTextTest method testNewlines.
@Test
public void testNewlines() {
String message = "hello\nworld";
ChatText text = ChatText.fromMessage(message);
assertEquals(message, text.getMessage());
}
Aggregations