Search in sources :

Example 6 with TempMovementType

use of eu.europa.ec.fisheries.schema.movement.v1.TempMovementType in project UVMS-Docker by UnionVMS.

the class TempMovementRestIT method getTempMovementTest.

@Test
public void getTempMovementTest() throws Exception {
    TempMovementType tempMovement = getTempMovement();
    TempMovementType createdTempMovement = TempMovementRestHelper.createTempMovement(tempMovement);
    TempMovementType fetchedTempMovement = TempMovementRestHelper.getTempMovement(createdTempMovement.getGuid());
    assertEquals(createdTempMovement, fetchedTempMovement);
}
Also used : TempMovementType(eu.europa.ec.fisheries.schema.movement.v1.TempMovementType) Test(org.junit.Test) AbstractRestServiceTest(eu.europa.ec.fisheries.uvms.docker.validation.common.AbstractRestServiceTest)

Example 7 with TempMovementType

use of eu.europa.ec.fisheries.schema.movement.v1.TempMovementType in project UVMS-Docker by UnionVMS.

the class TempMovementRestIT method createTempMovementNoValidLatitudeShouldFail.

@Test
public void createTempMovementNoValidLatitudeShouldFail() throws Exception {
    TempMovementType tempMovement = getTempMovement();
    tempMovement.getPosition().setLatitude(100d);
    HttpResponse response = TempMovementRestHelper.createTempMovementResponse(tempMovement);
    checkErrorResponse(response);
}
Also used : HttpResponse(org.apache.http.HttpResponse) TempMovementType(eu.europa.ec.fisheries.schema.movement.v1.TempMovementType) Test(org.junit.Test) AbstractRestServiceTest(eu.europa.ec.fisheries.uvms.docker.validation.common.AbstractRestServiceTest)

Aggregations

TempMovementType (eu.europa.ec.fisheries.schema.movement.v1.TempMovementType)7 AbstractRestServiceTest (eu.europa.ec.fisheries.uvms.docker.validation.common.AbstractRestServiceTest)6 Test (org.junit.Test)6 HttpResponse (org.apache.http.HttpResponse)2 VesselType (eu.europa.ec.fisheries.schema.movement.asset.v1.VesselType)1 MovementPoint (eu.europa.ec.fisheries.schema.movement.v1.MovementPoint)1 SimpleDateFormat (java.text.SimpleDateFormat)1 Date (java.util.Date)1