IntoImpl extends BaseSqlPart implements Into { @Nullable @Override public SqlPart previous() { return mPrevious; } IntoImpl(@Nullable final String databaseName, @NotNull final String tableName, @NotNull final SqlPart previous); @NotNull @Override InsertColumns columns(@NotNull final String... columnNames); @NotNull @Override Values values(@NotNull final Object... expressions); @Override void prependTo(@NotNull final RawSqlBuilder builder); @Nullable @Override SqlPart previous();  }
@Test public void previous_returnsProperItem() { SqlPart sqlPart = mock(SqlPart.class); IntoImpl into = new IntoImpl(null, "table", sqlPart); SqlPart result = into.previous(); assertThat(result, is(sqlPart)); }