优化
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.baiyue.lastleg.service;
|
||||
|
||||
import com.baiyue.lastleg.dto.LastlegOrderRequests;
|
||||
import com.baiyue.lastleg.dto.LastlegOrderSummary;
|
||||
import com.baiyue.lastleg.dto.ContainerPlanProgressDetail;
|
||||
import com.baiyue.lastleg.dto.ContainerPlanProgressSummary;
|
||||
import com.baiyue.lastleg.dto.ContainerArrivalTimeView;
|
||||
@@ -39,6 +40,7 @@ import java.math.BigDecimal;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.assertEquals;
|
||||
import static org.junit.jupiter.api.Assertions.assertFalse;
|
||||
import static org.junit.jupiter.api.Assertions.assertNotNull;
|
||||
import static org.junit.jupiter.api.Assertions.assertNull;
|
||||
import static org.junit.jupiter.api.Assertions.assertSame;
|
||||
import static org.junit.jupiter.api.Assertions.assertThrows;
|
||||
@@ -84,6 +86,20 @@ class LastlegOrderServiceTest {
|
||||
assertEquals("WT-WH-20260911-020225", LastlegOrderService.displayOrderNo(order));
|
||||
}
|
||||
|
||||
@Test
|
||||
void exposesStableContainerBookingIdInOrderSummary() {
|
||||
LastlegOrder order = new LastlegOrder();
|
||||
order.setId(11L);
|
||||
order.setOrderNo("LMO-1");
|
||||
order.setSourceContainerBookingId("BOOKING-1");
|
||||
|
||||
LastlegOrderSummary summary = ReflectionTestUtils.invokeMethod(
|
||||
service, "summary", order, List.of(), null, "UNSCHEDULED");
|
||||
|
||||
assertNotNull(summary);
|
||||
assertEquals("BOOKING-1", summary.sourceContainerBookingId());
|
||||
}
|
||||
|
||||
@BeforeEach
|
||||
void setUp() {
|
||||
service = new LastlegOrderService();
|
||||
|
||||
Reference in New Issue
Block a user