diff --git a/CHANGELOG.md b/CHANGELOG.md index 794e14f94..eda796717 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # CHANGELOG +## Next Releease + +- Fix `EasyPostTimeInTransitData` class and `easypostTimeInTransitData` property of `EstimatedDeliveryDate` class being publicly inaccessible + ## v7.1.0 (2024-01-08) - Adds `allChildren` function in User service to get a paginated list of child users diff --git a/src/main/java/com/easypost/model/EasyPostTimeInTransitData.java b/src/main/java/com/easypost/model/EasyPostTimeInTransitData.java new file mode 100644 index 000000000..bd5bb7cda --- /dev/null +++ b/src/main/java/com/easypost/model/EasyPostTimeInTransitData.java @@ -0,0 +1,10 @@ +package com.easypost.model; + +import lombok.Getter; + +@Getter +public class EasyPostTimeInTransitData { + private TimeInTransit daysInTransit; + private String easypostEstimatedDeliveryDate; + private String plannedShipDate; +} diff --git a/src/main/java/com/easypost/model/EstimatedDeliveryDate.java b/src/main/java/com/easypost/model/EstimatedDeliveryDate.java index 928d717e6..563051411 100644 --- a/src/main/java/com/easypost/model/EstimatedDeliveryDate.java +++ b/src/main/java/com/easypost/model/EstimatedDeliveryDate.java @@ -8,9 +8,3 @@ public class EstimatedDeliveryDate { private Rate rate; } -@Getter -class EasyPostTimeInTransitData { - private TimeInTransit daysInTransit; - private String easypostEstimatedDeliveryDate; - private String plannedShipDate; -} diff --git a/src/test/java/com/easypost/ShipmentTest.java b/src/test/java/com/easypost/ShipmentTest.java index 283ac2afd..e5b3b6a8c 100644 --- a/src/test/java/com/easypost/ShipmentTest.java +++ b/src/test/java/com/easypost/ShipmentTest.java @@ -713,6 +713,9 @@ public void testRetrieveEstimatedDeliveryDate() throws EasyPostException { .retrieveEstimatedDeliveryDate(shipment.getId(), Fixtures.plannedShipDate()); for (EstimatedDeliveryDate estimatedDeliveryDate : estimatedDeliveryDates) { assertNotNull(estimatedDeliveryDate.getEasypostTimeInTransitData()); + assertNotNull(estimatedDeliveryDate.getEasypostTimeInTransitData().getEasypostEstimatedDeliveryDate()); + assertNotNull(estimatedDeliveryDate.getEasypostTimeInTransitData().getDaysInTransit()); + assertNotNull(estimatedDeliveryDate.getEasypostTimeInTransitData().getDaysInTransit().getPercentile99()); } } }