Search in sources :

Example 21 with ProjectId

use of io.spine.test.projection.ProjectId in project core-java by SpineEventEngine.

the class StandShould method toProjectionCollection.

private static ImmutableCollection<Given.StandTestProjection> toProjectionCollection(Collection<ProjectId> values) {
    final Collection<Given.StandTestProjection> transformed = Collections2.transform(values, new Function<ProjectId, Given.StandTestProjection>() {

        @Override
        public StandTestProjection apply(@Nullable ProjectId input) {
            checkNotNull(input);
            return new StandTestProjection(input);
        }
    });
    final ImmutableList<Given.StandTestProjection> result = ImmutableList.copyOf(transformed);
    return result;
}
Also used : StandTestProjection(io.spine.server.stand.Given.StandTestProjection) ProjectId(io.spine.test.projection.ProjectId)

Aggregations

ProjectId (io.spine.test.projection.ProjectId)21 Test (org.junit.Test)13 Project (io.spine.test.projection.Project)6 Any (com.google.protobuf.Any)4 Version (io.spine.core.Version)4 Message (com.google.protobuf.Message)3 Event (io.spine.base.Event)3 Event (io.spine.core.Event)3 TestProjection (io.spine.server.projection.given.ProjectionRepositoryTestEnv.TestProjection)3 Duration (com.google.protobuf.Duration)2 EntityFilters (io.spine.client.EntityFilters)2 Topic (io.spine.client.Topic)2 GivenVersion (io.spine.core.given.GivenVersion)2 BoundedContext (io.spine.server.BoundedContext)2 StandTestProjection (io.spine.server.stand.Given.StandTestProjection)2 StandTestProjectionRepository (io.spine.server.stand.Given.StandTestProjectionRepository)2 TenantAwareTest (io.spine.server.tenant.TenantAwareTest)2 Task (io.spine.test.projection.Task)2 PrjProjectCreated (io.spine.test.projection.event.PrjProjectCreated)2 ArgumentMatcher (org.mockito.ArgumentMatcher)2