@Test
  public void testColumnsWithShortNames() {
    when(screen.getScreenWidth()).thenReturn(9);

    Table table = createTableStructure(3, "|", "A", "A", "A");
    RowGroup rowGroup = table.getLastRowGroup();
    Row row = rowGroup.newRow();
    row
        .newLeftCol("123")
        .newLeftCol("123")
        .newLeftCol("123");

    List<String> result = validateTable(table, true);

    assertThat(result)
        .hasSize(4)
        .containsExactly(
            "",
            "A0|A1|A2",
            "--|--|--",
            "..|..|..");
  }
Test Variations table-wide separator true false
geode-gfsh/src/test/java/org/apache/geode/management/internal/cli/result/TableBuilderTest.java