WithoutRowIdImpl extends BaseFinishedStatement implements WithoutRowId { @Nullable @Override public SqlPart previous() { return mPrevious; } WithoutRowIdImpl(@NotNull final SqlPart previous); @Override void prependTo(@NotNull final RawSqlBuilder builder); @Nullable @Override SqlPart previous();  }
@Test public void previous_returnsProperItem() { SqlPart sqlPart = mock(SqlPart.class); WithoutRowIdImpl withoutRowId = new WithoutRowIdImpl(sqlPart); SqlPart result = withoutRowId.previous(); assertThat(result, is(sqlPart)); }