Functional Weave
Code in Rust

logistics.incoterm-responsibility@1.0.0

vectors.json

6,852 bytes · view raw

[
  {"name": "EXW: the buyer does everything, even loading and export clearance", "args": ["EXW", 2020], "expect": {"rule": "EXW", "edition": 2020, "name": "Ex Works", "anyMode": true, "delivery": "At the seller's premises or another named place, placed at the buyer's disposal and not loaded.", "riskPassesAtDestination": false, "loadingAtOrigin": "buyer", "exportClearance": "buyer", "mainCarriage": "buyer", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "FCA: seller clears for export and hands over to the buyer's carrier", "args": ["FCA", 2020], "expect": {"rule": "FCA", "edition": 2020, "name": "Free Carrier", "anyMode": true, "delivery": "To the carrier or other person the buyer nominates: loaded on the buyer's transport at the seller's premises, or ready for unloading from the seller's transport at another named place.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "buyer", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "CPT: seller pays carriage but risk passes at the first carrier", "args": ["CPT", 2020], "expect": {"rule": "CPT", "edition": 2020, "name": "Carriage Paid To", "anyMode": true, "delivery": "Handed to the first carrier the seller contracts with; risk passes there, although the seller pays carriage to the named destination.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "CIP: all-risks cover, Institute Cargo Clauses (A), since 2020", "args": ["CIP", 2020], "expect": {"rule": "CIP", "edition": 2020, "name": "Carriage and Insurance Paid To", "anyMode": true, "delivery": "Handed to the first carrier the seller contracts with; risk passes there, although the seller pays carriage and insurance to the named destination.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": "seller", "insuranceCover": "Institute Cargo Clauses (A) or similar, at least 110% of the contract price", "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "DAP: risk passes at destination, the buyer unloads and clears import", "args": ["DAP", 2020], "expect": {"rule": "DAP", "edition": 2020, "name": "Delivered at Place", "anyMode": true, "delivery": "At the named place of destination, on the arriving means of transport, ready for unloading.", "riskPassesAtDestination": true, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "DPU: the only rule where the seller unloads", "args": ["DPU", 2020], "expect": {"rule": "DPU", "edition": 2020, "name": "Delivered at Place Unloaded", "anyMode": true, "delivery": "At the named place of destination, unloaded from the arriving means of transport.", "riskPassesAtDestination": true, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "seller", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "DDP: the seller pays import duties and VAT, the buyer still unloads", "args": ["DDP", 2020], "expect": {"rule": "DDP", "edition": 2020, "name": "Delivered Duty Paid", "anyMode": true, "delivery": "At the named place of destination, on the arriving means of transport, ready for unloading and cleared for import.", "riskPassesAtDestination": true, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "seller", "importDuties": "seller"}},
  {"name": "FAS: sea only, delivered alongside the ship", "args": ["FAS", 2020], "expect": {"rule": "FAS", "edition": 2020, "name": "Free Alongside Ship", "anyMode": false, "delivery": "Alongside the vessel the buyer nominates, at the named port of shipment.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "buyer", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "FOB: sea only, delivered on board", "args": ["FOB", 2020], "expect": {"rule": "FOB", "edition": 2020, "name": "Free On Board", "anyMode": false, "delivery": "On board the vessel the buyer nominates, at the named port of shipment.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "buyer", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "CFR: seller pays freight but risk passes on board", "args": ["CFR", 2020], "expect": {"rule": "CFR", "edition": 2020, "name": "Cost and Freight", "anyMode": false, "delivery": "On board the vessel at the port of shipment; risk passes there, although the seller pays freight to the named port of destination.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": null, "insuranceCover": null, "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "CIF: minimum cover, Institute Cargo Clauses (C)", "args": ["CIF", 2020], "expect": {"rule": "CIF", "edition": 2020, "name": "Cost, Insurance and Freight", "anyMode": false, "delivery": "On board the vessel at the port of shipment; risk passes there, although the seller pays freight and insurance to the named port of destination.", "riskPassesAtDestination": false, "loadingAtOrigin": "seller", "exportClearance": "seller", "mainCarriage": "seller", "insuranceBy": "seller", "insuranceCover": "Institute Cargo Clauses (C) or similar, at least 110% of the contract price", "unloadingAtDestination": "buyer", "importClearance": "buyer", "importDuties": "buyer"}},
  {"name": "DAT was replaced by DPU in 2020", "args": ["DAT", 2020], "expectError": "unknown Incoterms 2020 rule \"DAT\""},
  {"name": "codes are capitals", "args": ["fob", 2020], "expectError": "unknown Incoterms 2020 rule \"fob\""},
  {"name": "not an Incoterms rule", "args": ["C&F", 2020], "expectError": "unknown Incoterms 2020 rule \"C&F\""},
  {"name": "an edition with no data", "args": ["FOB", 2010], "expectError": "no data for Incoterms 2010"}
]