File tree Expand file tree Collapse file tree 2 files changed +15
-8
lines changed
src/test/java/com/flowingcode/vaadin/addons/xterm/integration Expand file tree Collapse file tree 2 files changed +15
-8
lines changed Original file line number Diff line number Diff line change 1919 */
2020package com .flowingcode .vaadin .addons .xterm .integration ;
2121
22+ import static com .flowingcode .vaadin .addons .xterm .integration .XTermTestUtils .makeFullLine ;
2223import static org .hamcrest .Matchers .is ;
2324import static org .hamcrest .Matchers .isEmptyString ;
2425import static org .junit .Assert .assertThat ;
25- import org .apache .commons .lang3 .StringUtils ;
2626import org .junit .Test ;
2727import org .openqa .selenium .Keys ;
2828
2929public class ConsoleFeatureIT extends AbstractViewTest {
3030
31- /** Returns a line that runs up to the right margin */
32- private String makeFullLine (XTermElement term , boolean hasPrompt ) {
33- int cols = term .getColumnWidth ();
34- int x = hasPrompt ? term .cursorPosition ().x : 0 ;
35- return StringUtils .repeat ("0123456789" , cols / 10 + 1 ).substring (0 , cols - x );
36- }
37-
3831 @ Test
3932 public void testWriteWrappedLine () throws InterruptedException {
4033 XTermElement term = $ (XTermElement .class ).first ();
Original file line number Diff line number Diff line change 1+ package com .flowingcode .vaadin .addons .xterm .integration ;
2+
3+ import org .apache .commons .lang3 .StringUtils ;
4+
5+ public class XTermTestUtils {
6+
7+ /** Returns a line that runs up to the right margin */
8+ public static String makeFullLine (XTermElement term , boolean hasPrompt ) {
9+ int cols = term .getColumnWidth ();
10+ int x = hasPrompt ? term .cursorPosition ().x : 0 ;
11+ return StringUtils .repeat ("0123456789" , cols / 10 + 1 ).substring (0 , cols - x );
12+ }
13+
14+ }
You can’t perform that action at this time.
0 commit comments