Skip to content

ATS-ACC-PRD-011Offer a collection of products as a bundle: Capability Test Specification

Markdown

ATS-ACC-PRD-011

Offer a collection of products as a bundle: Capability Test Specification

Markdown
  • DocumentProposed

KindAcceptance test setProduct areaAccountingModuleProductsRevision3

Read atservices-accounting f47cb263react-console baf6dae3

Coverage

  • Rule covered
  • Transition covered
  • Validation covered
  • Permission gap: FND-ACC-PRD-060
  • Edge gap: FND-ACC-PRD-060
  • Failure gap: FND-ACC-PRD-060
  • Boundary covered
  • Concurrency gap: FND-ACC-PRD-060
  • Invariant covered
  • Interaction covered

Test Scenarios

9 scenarios proving CAP-ACC-PRD-011; 8 bound to an existing test.

01 Kinds without bundling reject componentsvalidationunitnegativetest
Proves
BR-CAP-ACC-PRD-011-01
Preconditions
Donation and Legacy Products exist.
Steps
Add a component to each.
Expected
Both requests fail.
Data
Donation and Legacy Products exist.
Bound to
services-accounting:modules/products/tests/e2e/products.e2e.spec.js#answers 400 to bundled products on a Legacy Product
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses components on a Donation Product
02 Bundle components must be valid and distinctvalidationunitnegativetest
Proves
BR-CAP-ACC-PRD-011-02
Preconditions
The fixtures include products from two units and an unsellable kind.
Steps
Try foreign-unit, unsellable, missing, self and repeated components.
Expected
Every invalid relationship fails.
Data
The fixtures include products from two units and an unsellable kind.
Bound to
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses a component of another business unit, naming both units
03 Retired components distinguish retained from newtransitionunitnegativetest
Proves
BR-CAP-ACC-PRD-011-03
Preconditions
A bundle holds a component later retired and another retired product exists.
Steps
Resave the held component and try adding the other retired product.
Expected
The held relationship remains and the new one fails.
Data
A bundle holds a component later retired and another retired product exists.
Bound to
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#keeps a retired component the bundle already holds when a replacement resends it, and refuses a new retired one
services-accounting:modules/products/tests/unit/rules/product-rules.spec.js#keeps a retired component the bundle already holds
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#keeps a retired component the bundle already holds when a replacement resends it, and refuses a new retired one
04 Indirect self-inclusion failsinvariantunitnegativetest
Proves
BR-CAP-ACC-PRD-011-04
Preconditions
A already includes B.
Steps
Add A to B.
Expected
The cycle is rejected.
Data
A already includes B.
Bound to
services-accounting:modules/products/tests/e2e/products.e2e.spec.js#answers 400 when a part would include the bundle that includes it
services-accounting:modules/products/tests/unit/rules/product-rules.spec.js#finds a bundle reached again through its components
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses closing a cycle: B including A when A includes B
05 Component allocations require explicit pricesvalidationunitnegativetest
Proves
BR-CAP-ACC-PRD-011-05
Preconditions
An existing bundle can take a component.
Steps
Submit one component without a price and another priced zero.
Expected
The omitted allocation fails without writes and zero succeeds.
Data
An existing bundle can take a component.
Bound to
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses a component sent without a price, naming it, and stores nothing (ACCT-M1 D10.1, DEF-ACT-0107)
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses a component sent without a price, naming it, and stores nothing (ACCT-M1 D10.1, DEF-ACT-0107)
06 Quantity-weighted allocations fit bundle pricesruleunitnegativetest
Proves
BR-CAP-ACC-PRD-011-06
Preconditions
A bundle costs 5000 minor units and has member-price variants.
Steps
Try exact totals, quantity-driven excess and member allocations exceeding or lacking backing.
Expected
Exact totals pass and excess allocations fail.
Data
A bundle costs 5000 minor units and has member-price variants.
Bound to
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses component prices that add up to more than the product price, in Rhythm 1.0’s words
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses component member prices that add up to more than the product member price, in Rhythm 1.0’s words
services-accounting:modules/products/tests/unit/rules/product-rules.spec.js#multiplies each price and member price by its quantity
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#totals each component price times its quantity (ACCT-M1 D12 A2)
07 Bundle size is boundedboundaryunitnegativetest
Proves
BR-CAP-ACC-PRD-011-08
Preconditions
A product can take component fixtures.
Steps
Submit fifty-one components.
Expected
The request fails its collection limit.
Data
A product can take component fixtures.
Bound to
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses more than 50 bundled products
08 Console corrections preserve bundlesinteractionbrowsertest
Proves
BR-CAP-ACC-PRD-011-09
Preconditions
An API-configured bundle exists.
Steps
Open and save it through the console.
Expected
Bundle controls stay hidden and components remain unchanged.
Data
An API-configured bundle exists.
Bound to
Source
react-console:acceptance/accounting/playwright/journeys/products/ACT-ACC-0110.spec.ts#ACT-ACC-0110
09 Bundle retirement and setup allocation retain independent safeguardsinteractionapinegativeproposed
Proves
BR-CAP-ACC-PRD-011-03 BR-CAP-ACC-PRD-011-06 BR-CAP-ACC-PRD-005-02 BR-CAP-ACC-PRD-006-01 BR-CAP-ACC-PRD-016-06
Preconditions
A bundle includes an active product and has financial shares.
Steps
Retire the included product, resave the relationship, try to delete the component, and attempt setup shares above the bundle standard price.
Expected
The held component remains valid and protected from deletion; excessive financial shares refuse the setup save.
Data
A bundle includes an active product and has financial shares.
Source
services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#keeps a retired component the bundle already holds when a replacement resends it, and refuses a new retired one; services-accounting:modules/products/services/rules/product-rules.ts:listPrice; services-accounting:modules/products/services/rules/product-rules.ts:bundleTotalsProblem; services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#retires the product at version 2, changing nothing else; services-accounting:modules/products/tests/integration/services/persistence/products.integration.spec.js#refuses deleting a product another product bundles, 409, and keeps it; services-accounting:modules/products/services/rules/product-rules.ts:listPrice; services-accounting:modules/products/services/rules/product-rules.ts:revenueSplitsProblem

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.