ATS-MBR-MEM-013Bill renewals in runs, on demand or on a schedule: Acceptance Test Set
MarkdownBill renewals in runs, on demand or on a schedule: Acceptance Test Set
Coverage
Test Scenarios
13 scenarios proving CAP-MBR-MEM-013; 13 bound to an existing test.
01 Every wrong template, run or recurring run is refused and leaves nothingapinegativetest
- Proves
BR-CAP-MBR-MEM-013-01 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Create templates with a drop and no drop reason, a reason of the wrong kind, and malformed filters.
- Expected
- Each is refused with its reason; nothing is saved.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:tests/acceptance/billing/MBR-ACC-0402.acceptance.ts#MBR-ACC-0402
02 A run copies its template so its plan is reproducibleapitest
- Proves
BR-CAP-MBR-MEM-013-02 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Create a template, then a run from it, then change the template.
- Expected
- The run keeps the documents it copied.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:tests/e2e/billing-api.e2e.spec.ts#creates a template
03 Planning takes the right candidatesunittest
- Proves
BR-CAP-MBR-MEM-013-03 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Plan over principal, flow-down, renewed, never-ending, suspended and filtered-out terms.
- Expected
- Only principal, unrenewed, ending, unsuspended terms of allowed types and packages are candidates.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/unit/run-plan.spec.ts#takes a principal membership’s term in range
04 Candidates are classed renewing or lapsed by graceunittest
- Proves
BR-CAP-MBR-MEM-013-04 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Class terms ending just inside and just outside the run's date less grace.
- Expected
- Renewing and lapsed.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/unit/run-plan.spec.ts#classes a term ending on or after the date less its grace as renewing
05 Each candidate is planned the right actionsunittest
- Proves
BR-CAP-MBR-MEM-013-05 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Plan renewing members with and without a stored method, do-not-renew and do-not-drop members, and lapsed members.
- Expected
- Renewal or auto-renewal orders with the card warning, notices and reminders, drops; flagged members left alone unless included.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/unit/run-plan.spec.ts#plans a renewing term’s renewal order, notice and each reminder
06 A plan's statistics add upunittest
- Proves
BR-CAP-MBR-MEM-013-06 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Plan a population and read the statistics.
- Expected
- Candidates, classes, exclusions and actions are counted.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/unit/run-plan.spec.ts#counts the candidates, their classes, the exclusions and the planned actions
07 Execution acts once, refuses stale actions and repeats harmlesslyapitest
- Proves
BR-CAP-MBR-MEM-013-07 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Correct a planned term, execute the run, then execute again.
- Expected
- The corrected term's action is stale; every other action settles once; the second execution does nothing.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/integration/billing-runs.integration.spec.ts#refuses as stale an action whose term changed after planning
08 Execution places one order per renewing member and drops the lapsedapitest
- Proves
BR-CAP-MBR-MEM-013-08 BR-CAP-MBR-MEM-013-09 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Execute a planned run over the FAA population.
- Expected
- One order per renewing member (Jo's with both chapters' dues), notices and reminders submitted, the lapsed terms dropped with the run's reason.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/integration/billing-runs.integration.spec.ts#executes on the jobs engine: one order per renewing candidate (Jo’s with both dues chapters), a notice and reminder each, one drop per lapsed term
09 Run operations need the version read and an allowing statusapinegativetest
- Proves
BR-CAP-MBR-MEM-013-11 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Cancel a draft and a planned run, then try to plan, execute or cancel them again; act at a stale version.
- Expected
- Cancelled runs keep their planned actions and refuse every later operation; the stale request is refused.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:tests/acceptance/billing/MBR-ACC-0406.acceptance.ts#MBR-ACC-0406
10 A recurring run creates one run per occurrenceapitest
- Proves
BR-CAP-MBR-MEM-013-12 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Deliver an occurrence twice.
- Expected
- One run, planned on the occurrence's business day.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:modules/billing/tests/integration/billing-runs.integration.spec.ts#creates and plans one run per occurrence of a recurring run, a redelivered occurrence finding it
12 Readers read billing and cannot change itapinegativetest
- Proves
BR-CAP-MBR-MEM-013-14 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- A reader reads a run and tries to plan it.
- Expected
- The read succeeds; planning is refused.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:tests/e2e/billing-api.e2e.spec.ts#lets a reader read the run and refuses it the planning
13 Notices reach a person's first address and skip those without oneapitest
- Proves
BR-CAP-MBR-MEM-013-15 - Preconditions
- The well-known FAA workspace fixtures, or a workspace the test builds from them.
- Steps
- Execute notices for a member with addresses, one without, and an organization member.
- Expected
- One request per notice to the first address; the other two skipped as having no recipient.
- Data
- FAA programs, packages, units and members from the integration seed.
- Bound to
- Source
- services-membership:tests/acceptance/billing/MBR-ACC-0418.acceptance.ts#MBR-ACC-0418