13 use Magento\Sales\Model\Order\Shipment\TrackFactory;
41 private $objectManager;
56 public function testShipmentRemoveTrack()
58 $shipmentCollection = $this->objectManager->get(Collection::class);
60 $shipment = $shipmentCollection->getFirstItem();
62 $trackEntity = $this->objectManager->get(TrackFactory::class)
80 $trackEntity = $this->objectManager->get(ShipmentTrackRepositoryInterface::class)
85 'resourcePath' =>
'/V1/shipment/track/' . $trackEntity->getEntityId(),
91 'operation' => self::SERVICE_READ_NAME .
'deleteById',
98 $this->assertNoAvailableTrackItems(
$shipment->getId());
107 private function assertNoAvailableTrackItems($shipmentId)
114 $items = $this->objectManager->get(ShipmentTrackRepositoryInterface::class)
118 self::assertEmpty(
$items);
const CUSTOM_CARRIER_CODE
_webApiCall( $serviceInfo, $arguments=[], $webApiAdapterCode=null, $storeCode=null, $integration=null)
const SHIPMENT_INCREMENT_ID
foreach($order->getItems() as $orderItem) $shipment
static getObjectManager()