### Question:
SqlScript { @Override @NotNull public String toString() { switch (myCount) { case 0: return ""; case 1: return myStatements[0].getSourceText(); default: final StringBuilder b = new StringBuilder(); final String delimiterString = getScriptDelimiterString(); b.append(myStatements[0].getSourceText()); for (int i = 1; i < myCount; i++) { if (b.charAt(b.length()-1) != '\n') b.append('\n'); b.append(delimiterString).append('\n'); b.append(myStatements[i].getSourceText()); } return b.toString(); } } SqlScript(@NotNull final String... statements);  SqlScript(@NotNull final SqlStatement... statements);  SqlScript(@NotNull final SqlScript... scripts);  SqlScript(@NotNull final Collection<? extends SqlStatement> statements); private  SqlScript(@NotNull final SqlStatement[] statements, boolean copy); @NotNull List<? extends SqlStatement> getStatements(); boolean hasStatements(); int count(); @Override @NotNull String toString();  }### Answer:
@Test public void toString_contains_all_commands() { SqlScript script = new SqlScript("command 1", "command 2"); final String text = script.toString(); assertThat(text).contains("command 1") .contains("command 2"); }