22 package com.realtime.crossfire.jxclient.util;
24 import org.junit.Assert;
25 import org.junit.Test;
44 Assert.assertEquals(
"a b c d e f g h i j k l m n o p q r s t u v w x y<br>"+
"A B C D E",
StringSplitter.
splitAsHtml(
"a b c d e f g h i j k l m n o p q r s t u v w x y A B C D E"));
45 Assert.assertEquals(
"a b c d e f g h i j k l m n o p q r s t u v w x y<br>"+
"A B C D E F G H I J K L M N O P Q R S T U V W X Y<br>"+
"a b c d e f g h i j k l m n o p q r s t u v w x y<br>"+
"A B C D E",
StringSplitter.
splitAsHtml(
"a b c d e f g h i j k l m n o p q r s t u v w x y A B C D E F G H I J K L M N O P Q R S T U V W X Y a b c d e f g h i j k l m n o p q r s t u v w x y A B C D E"));
46 Assert.assertEquals(
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa<br>"+
"bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb<br>"+
"cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc<br>"+
"cccccccccccccccccccc ddddddddddddddddddddddddddddd<br>"+
"eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee<br>"+
"ffffffffffffffffffffffffffffff<br>"+
"gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg<br>"+
"gggggggggggggggggggg",
StringSplitter.
splitAsHtml(
"aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb cccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc ddddddddddddddddddddddddddddd eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee ffffffffffffffffffffffffffffff gggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggggg"));
void testSplit()
Checks that StringSplitter#splitAsHtml(String) does work.
static String splitAsHtml(@NotNull final String message)
Splits the given string into lines and returns the lines separated by "<br>".
Utility class for splitting strings.
Regression tests for class StringSplitter.