Package-level declarations

Base implementations for CRUD API tests

Description

This is the base package for CRUD test implementations.

Types

Link copied to clipboard
class AdjustableInstantProvider(instant: Instant = Instant.now().with(ChronoField.NANO_OF_SECOND, 0), adjustmentMillis: Long = 0) : InstantProvider

Implementation of InstantProvider that is adjustable in milliseconds by the use of adjust to simulate changes in time

Link copied to clipboard
abstract class CRUDServiceTest<I : Serializable, E : CRUDEntity<I>, M : CRUDModel<I>, CM : CRUDCreateModel, UM : CRUDUpdateModel, Mapper : CRUDMapper<I, E, M, CM, UM>, R : CRUDRepository<I, E>, S : CRUDService<I, E, M, CM, UM, R, Mapper>, TestData : CRUDTestData<I, E, M, CM, UM, TestData>>(typeName: String, mapper: Mapper, testData: TestData)

Base class for unit tests of CRUD services

Link copied to clipboard
abstract class CRUDTestData<I : Serializable, E : CRUDEntity<I>, M : CRUDModel<I>, CM : CRUDCreateModel, UM : CRUDUpdateModel, TestData : CRUDTestData<I, E, M, CM, UM, TestData>>(typeName: String)

Test data provider and mapper to convert between models and entities in tests

Link copied to clipboard
class InMemoryCRUDRepository<I : Serializable, E : CRUDEntity<I>, CM : CRUDCreateModel, TestData : CRUDTestData<I, E, *, CM, *, TestData>>(typeName: String, testData: TestData) : CRUDRepository<I, E>

In-memory implementation of CRUDRepository for testing