use of io.crnk.jpa.JpaModule in project crnk-framework by crnk-project.
the class QueryFactoryDiscoveryTest method checkJpaModuleIntegration.
@Test
public void checkJpaModuleIntegration() {
TransactionRunner transactionRunner = Mockito.mock(TransactionRunner.class);
EntityManager em = Mockito.mock(EntityManager.class);
JpaModule module = JpaModule.newServerModule(em, transactionRunner);
Assert.assertEquals(QuerydslQueryFactory.class, module.getQueryFactory().getClass());
}
use of io.crnk.jpa.JpaModule in project crnk-framework by crnk-project.
the class AbstractOperationsTest method setup.
@Before
public void setup() {
client = new CrnkClient(getBaseUri().toString());
client.setActionStubFactory(JerseyActionStubFactory.newInstance());
client.getHttpAdapter().setReceiveTimeout(10000000, TimeUnit.MILLISECONDS);
MetaModule metaModule = MetaModule.create();
metaModule.addMetaProvider(new ResourceMetaProvider());
client.addModule(metaModule);
JpaModule module = JpaModule.newClientModule();
setupModule(module, false);
client.addModule(module);
setNetworkTimeout(client, 10000, TimeUnit.SECONDS);
}
Aggregations