Skip to content

ATS-COM-CAT-012Configure product purchasing and price adjustments: Capability Test Specification

Markdown

ATS-COM-CAT-012

Configure product purchasing and price adjustments: Capability Test Specification

Markdown
  • DocumentProposed
  • Product intentProposed

KindAcceptance test setProduct areaCommerceModuleCatalog and Selling ConfigurationRevision2

Read atservices-commerce c8b66a98react-console baf6dae3

Coverage

  • Rule covered
  • Transition covered
  • Validation covered
  • Permission covered
  • Edge gap: FND-COM-CAT-066
  • Failure gap: FND-COM-CAT-066
  • Boundary gap: FND-COM-CAT-066
  • Concurrency gap: FND-COM-CAT-066
  • Invariant covered
  • Interaction covered

Test Scenarios

10 scenarios proving CAP-COM-CAT-012; 7 bound to an existing test.

01 Unconfigured settings return defaults and replacement resets omissionsruleapitest
Proves
BR-CAP-COM-CAT-012-02 INV-DOM-COM-CAT-004-12
Preconditions
A product has no purchasing-settings record
Steps
Read settings and save a partial selection
Expected
Read returns defaults with the unconfigured indication; omitted fields take defaults on save
Data
none
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#reads a product without a row as the defaults, not configured
02 Selection strategy changes the qualifying price choseninteractionapitest
Proves
BR-CAP-COM-CAT-012-03 AS-JNY-COM-CAT-002-04
Preconditions
A buyer qualifies for Member and Student
Steps
Quote using lowest, rank and lowest again
Expected
Selection produces Student, Member and Student pricing respectively
Data
Student and Member price rows
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#prices the student member at the student price under lowest (premise)
03 Invalid settings preserve the existing recordvalidationapinegativetest
Proves
BR-CAP-COM-CAT-012-04
Preconditions
The product has saved settings
Steps
Reference an unknown schedule, unsupported selection and unknown role
Expected
Each invalid save fails and preserves the settings
Data
none
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#refuses a schedule the workspace does not have, 400, and leaves the settings as they were
04 Pricing-handler activation controls its adjustmenttransitionapitest
Proves
BR-CAP-COM-CAT-012-06
Preconditions
The product price is twenty dollars
Steps
Register a 2.50-dollar adjustment, deactivate it and remove it
Expected
Quotes become 22.50 dollars, then return to twenty dollars for both later states
Data
Fixture handler registry
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-extensions.e2e.spec.js#adds the function’s $2.50 to the next quote: $20.00 price row and $2.50 extension, $22.50
05 Pricing-function requests reject mismatched and handler-owned fieldsvalidationapinegativetest
Proves
BR-CAP-COM-CAT-012-07
Preconditions
A product function can be registered
Steps
Submit another product or workspace, a timeout and no handler
Expected
Invalid registration fails without a saved function
Data
none
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-extensions.e2e.spec.js#refuses a body naming another product
06 Grid validation requires Standard coverageinvariantunitnegativetest
Proves
BR-CAP-COM-CAT-012-08
Preconditions
Member pricing exists without Standard in a cell
Steps
Validate missing, inherited and prohibited Standard configurations
Expected
Missing coverage identifies the cell; inherited and prohibited coverage pass
Data
none
Bound to
Source
react-console:lib/commerce/pricing/__tests__/rules.test.ts#refuses a period with a Member price and no Standard price, naming the cell
07 Pricing configuration separates read and write authoritypermissionapinegativetest
Proves
BR-CAP-COM-CAT-012-10
Preconditions
The caller holds read grants for settings and functions
Steps
Inspect both resources and attempt changes
Expected
Inspection succeeds and writes fail
Data
Read-exclusively persona
Bound to
Source
services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#lets a read-only principal read, and refuses it the PUT, 403 permission_missing, the settings as they were
08 Audience deactivation changes a configured price strategyinteractionapiproposed
Proves
BR-CAP-COM-CAT-010-06 BR-CAP-COM-CAT-012-03
Preconditions
Member and Student qualify for one product.
Steps
Select rank pricing, deactivate the first audience, quote, reactivate and quote again.
Expected
The inactive audience is skipped without losing its stored price and returns to selection after reactivation.
Data
Run-owned workspace and records; fixed clock where dates are exercised.
Source
services-commerce:modules/pricing/tests/integration/services/inputs/pricing-inputs.integration.spec.js#loads the active audiences in rank order, the inactive left out, and the period each schedule is in at the instant,services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#prices the same buyer at the member price under rank, Member coming before Student members
09 A product reference retains its selected scheduleinteractionapiproposed
Proves
BR-CAP-COM-CAT-011-07 BR-CAP-COM-CAT-012-04
Preconditions
A product follows Annual and another schedule is inactive.
Steps
Attempt to disable Annual and select the inactive schedule; move the product to a valid alternative and disable Annual.
Expected
Referenced and inactive choices refuse; the unreferenced schedule can be disabled.
Data
Run-owned workspace and records; fixed clock where dates are exercised.
Source
services-commerce:modules/pricing/tests/integration/services/persistence/pricing-schedules.integration.spec.js#refuses with schedule_in_use, the count in the sentence, and the count and the first five product ids in the details,services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#refuses an unknown organization role id with 400 naming it, and stores nothing (COM-ACC-0799)
10 Purchasing strategy and handler activity alter the quoteinteractionapiproposed
Proves
BR-CAP-COM-CAT-012-03 BR-CAP-COM-CAT-012-06 BR-CAP-COM-CAT-013-01
Preconditions
Member and Student qualify and a product handler adds a fixed amount.
Steps
Quote under lowest and rank, then disable the handler and repeat.
Expected
The selected audience follows each strategy and the disabled handler contributes no adjustment.
Data
Run-owned workspace and records; fixed clock where dates are exercised.
Source
services-commerce:modules/pricing/tests/e2e/product-purchasing-settings.e2e.spec.js#prices the same buyer at the member price under rank, Member coming before Student members,services-commerce:modules/pricing/tests/e2e/product-extensions.e2e.spec.js#keeps the row and ignores it when it is put inactive: back to $20.00,services-commerce:modules/pricing/tests/unit/engine/engine.spec.js#prices the hoodies through the member cell, the variant, the bulk rule and the store’s line discount, in that order

The Markdown files under specs/ in rhythmsoftware/rhythm-v2-docs are the canonical source of truth. This reader is a generated, read-only projection of them.