Search in sources :

Example 6 with Presentation

use of org.rembx.jeeshop.catalog.model.Presentation in project jeeshop by remibantos.

the class PresentationResourceCT method createTestPresentation.

private Presentation createTestPresentation() {
    entityManager.getTransaction().begin();
    Presentation presentation = new Presentation("fr_FR", "presentation test", "testShortDesc", "testLongDesc");
    entityManager.persist(presentation);
    entityManager.getTransaction().commit();
    return presentation;
}
Also used : Presentation(org.rembx.jeeshop.catalog.model.Presentation)

Example 7 with Presentation

use of org.rembx.jeeshop.catalog.model.Presentation in project jeeshop by remibantos.

the class PresentationResourceCT method find_shouldReturnPresentation.

@Test
public void find_shouldReturnPresentation() {
    Presentation presentation = new Presentation("en_GB", "presentation1", "short description", "long description");
    service = new PresentationResource(entityManager, null).init(null, null, presentation);
    assertThat(service.find()).isEqualTo(presentation);
}
Also used : Presentation(org.rembx.jeeshop.catalog.model.Presentation) Test(org.junit.jupiter.api.Test)

Aggregations

Presentation (org.rembx.jeeshop.catalog.model.Presentation)7 Test (org.junit.jupiter.api.Test)4 PermitAll (javax.annotation.security.PermitAll)2 CatalogItem (org.rembx.jeeshop.catalog.model.CatalogItem)2 UUID (java.util.UUID)1 Catalog (org.rembx.jeeshop.catalog.model.Catalog)1 Store (org.rembx.jeeshop.catalog.model.Store)1