use of org.qi4j.sample.dcicargo.sample_a.data.shipping.cargo.Cargos in project qi4j-sdk by Qi4j.
the class BookNewCargoTest method deviation_2b_3_DeadlineTomorrowIsOkay.
@Test
public void deviation_2b_3_DeadlineTomorrowIsOkay() throws Exception {
UnitOfWork uow = module.currentUnitOfWork();
Location HONGKONG = uow.get(Location.class, CNHKG.code().get());
Location STOCKHOLM = uow.get(Location.class, SESTO.code().get());
Cargos CARGOS = uow.get(Cargos.class, CargosEntity.CARGOS_ID);
new BookNewCargo(CARGOS, HONGKONG, STOCKHOLM, day(1)).book();
}
use of org.qi4j.sample.dcicargo.sample_a.data.shipping.cargo.Cargos in project qi4j-sdk by Qi4j.
the class BookNewCargoTest method deviation2a_OriginAndDestinationSame.
@Test(expected = RouteException.class)
public void deviation2a_OriginAndDestinationSame() throws Exception {
UnitOfWork uow = module.currentUnitOfWork();
Location HONGKONG = uow.get(Location.class, CNHKG.code().get());
Cargos CARGOS = uow.get(Cargos.class, CargosEntity.CARGOS_ID);
new BookNewCargo(CARGOS, HONGKONG, HONGKONG, day(17)).book();
}
Aggregations