---
id: TST-COM-FUL-085
title: Zone strategy rating
kind: unit
product_area: commerce
module: fulfillment
revision: 1
status: draft
source_sha:
  services-commerce: c8b66a98e2490617aec38ba5c8165dd9bd0a8f9b
  react-console: baf6dae382d6f41dce976c7f848667ccc37e076f
repository: services-commerce
files:
  - modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js
implements:
  - ATS-COM-FUL-011-02
  - ATS-COM-FUL-011-03
  - ATS-COM-FUL-011-07
environment: mock
implementation_state: implemented
latest_result: not-run
latest_run_at: null
latest_run_ref: null
conformance: not-verified
estimated_minutes: 1
isolation: 'In-memory inputs, recorded calls and test-owned doubles; no shared customer records.'
evidence:
  - repository: services-commerce
    path: modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js
    test_titles:
      - 'matches a zone naming nothing to every address, and to no address at all'
      - 'matches a country zone to its countries alone, case-insensitively on the address'
      - >-
        matches a region zone within its country without case, and a prefix zone on the postal code
        without case or spaces
      - never matches an inactive zone
      - ranks a prefix over a region over a country over anywhere
      - >-
        picks the most specific matching zone, and the first of equals in the order given (priority,
        name, id)
      - 'charges a flat strategy once, whatever the units'
      - 'charges a per-unit strategy per UNIT shipped, never per line, plus its base once'
      - >-
        charges a weight-band strategy the first band the weight fits, the open-ended band taking
        the rest
      - 'leaves a weight past every closed band unrated, by name'
      - 'hands a carrier strategy to the port, unless free shipping already applies'
      - 'makes an option free at or above free_above_minor, measured against the merchandise subtotal'
      - leaves a strategy in another currency unrated
      - 'rates a pickup strategy at zero, whatever the units, the weight or the subtotal'
      - 'shows a pickup strategy with the location named on it, its address and its instructions'
      - shows a pickup strategy naming a warehouse with the warehouse’s name and address
      - shows no location for a pickup strategy whose warehouse was not given
    scenario_anchors:
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#matches a
        zone naming nothing to every address, and to no address at all
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#matches a
        country zone to its countries alone, case-insensitively on the address
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#matches a
        region zone within its country without case, and a prefix zone on the postal code without
        case or spaces
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#never
        matches an inactive zone
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#ranks a
        prefix over a region over a country over anywhere
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#picks the
        most specific matching zone, and the first of equals in the order given (priority, name, id)
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#charges a
        flat strategy once, whatever the units
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#charges a
        per-unit strategy per UNIT shipped, never per line, plus its base once
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#charges a
        weight-band strategy the first band the weight fits, the open-ended band taking the rest
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#leaves a
        weight past every closed band unrated, by name
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#makes an
        option free at or above free_above_minor, measured against the merchandise subtotal
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#leaves a
        strategy in another currency unrated
      - >-
        services-commerce:modules/shipping/tests/unit/rating/zone-strategy-rating.spec.js#rates a
        pickup strategy at zero, whatever the units, the weight or the subtotal
---

# Zone strategy rating

## Verification Boundary

This suite checks zone strategy rating with controlled inputs and recorded dependencies. Its entry points remain within the process.

## What This Suite Proves

The bound scenarios identify the assertions this suite contributes. Source anchors retain the exact test cases; where a capability scenario has several contributing suites, a single binding does not imply that every branch runs here.

## What It Does Not Prove

Controlled inputs do not establish database enforcement, deployed integration or browser behavior. A recorded call is evidence about the adapter contract rather than a remote operation.

## Real Dependencies and Test Doubles

The imported logic is real; test inputs and dependency responses are controlled.

## Must Not Be Doubled

Keep the imported production logic and its request construction real. Record dependency calls and refusals rather than replacing the behavior being asserted.
