InsertColumnsImpl extends BaseSqlPart implements InsertColumns { @Nullable @Override public SqlPart previous() { return mPrevious; } InsertColumnsImpl(@NotNull final String[] columnNames, @NotNull final SqlPart previous); @NotNull @Override Values values(@NotNull final Object... expressions); @Override void prependTo(@NotNull final RawSqlBuilder builder); @Nullable @Override SqlPart previous(); int getColumnCount();  }
@Test public void previous_returnsProperItem() { SqlPart sqlPart = mock(SqlPart.class); InsertColumnsImpl insertColumns = new InsertColumnsImpl(new String[] {"a", "b", "c"}, sqlPart); SqlPart result = insertColumns.previous(); assertThat(result, is(sqlPart)); }