Skip to content

ATS-CRM-DQ-013Resolve differences in the merge preview: Capability Test Specification

Markdown

ATS-CRM-DQ-013

Resolve differences in the merge preview: Capability Test Specification

Markdown
  • DocumentProposed

Planning

Proves capability
CAP-CRM-DQ-013

Design

Executed by
TST-CRM-DQ-176, TST-CRM-DQ-181, TST-CRM-DQ-183

KindAcceptance test setProduct areaCRMModuleDuplicate Review and Record MergingRevision1

Read atservices-crm a8d1364freact-console baf6dae3

Coverage

  • Rule covered
  • Transition covered
  • Validation covered
  • Permission gap: FND-CRM-DQ-064
  • Edge gap: FND-CRM-DQ-064
  • Failure covered
  • Boundary gap: FND-CRM-DQ-064
  • Concurrency covered
  • Invariant covered
  • Interaction covered

Test Scenarios

22 scenarios proving CAP-CRM-DQ-013; 14 bound to an existing test.

01 Preview questions represent incompatible retained valuesruleunittest
Proves
BR-CAP-CRM-DQ-013-01 BR-CAP-CRM-DQ-013-02
Preconditions
Prepare identical, sole and conflicting field values.
Steps
Compute a plan.
Expected
Identical and sole values need no question; optional conflicts offer existing values and clearing.
Data
The existing scenario setup supplies the required records.
Bound to
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#is no conflict when every participant holds the same value
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#is no conflict when only one participant holds a value, which the survivor then takes
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#offers clearing the field as well as each value held
Source
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#is no conflict when every participant holds the same value
02 Default selection explains its rankingruleapitest
Proves
BR-CAP-CRM-DQ-013-03
Preconditions
Prepare survivor-held values, a survivor gap with a majority and a gap without a majority.
Steps
Build previews.
Expected
Defaults select the survivor, then explain the majority count or latest field change.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#is a conflict defaulting to the survivor's value when two participants differ
03 Required unanswered questions prevent executiontransitionapinegativetest
Proves
BR-CAP-CRM-DQ-013-04
Preconditions
A plan contains an open required conflict.
Steps
Request execution.
Expected
The plan needs decisions and execution reports not ready.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#plans it as needing a decision rather than ready
04 Decision updates merge and clear independentlyinvariantapitest
Proves
BR-CAP-CRM-DQ-013-05
Preconditions
A preview contains two questions.
Steps
Answer each separately, clear one and then try answering and clearing together.
Expected
Answers accumulate, clearing affects only its question and the conflicting request fails.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#keeps the first answer when the second request answers only the other conflict
05 Unknown resolution leaves the saved plan intactvalidationapinegativetest
Proves
BR-CAP-CRM-DQ-013-06
Preconditions
An existing plan has earlier answers.
Steps
Submit an answer for an unavailable question.
Expected
The refusal identifies the invalid resolution and preserves earlier answers.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#refuses it as an invalid resolution rather than storing a decision nobody can apply
06 Old plan versions cannot overwrite decisionsconcurrencyapinegativetest
Proves
BR-CAP-CRM-DQ-013-07
Preconditions
Read a plan before another update changes it.
Steps
Submit an update with the earlier version.
Expected
The service refuses it without a write.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/integration/services/merges/merge-plan-decisions.integration.spec.js#leaves both decisions on the plan, at the version it was refused against
07 Changed source values require another approvalfailureapinegativetest
Proves
BR-CAP-CRM-DQ-013-08
Preconditions
A chosen job title changes after preview approval.
Steps
Execute, reopen the plan and attempt execution again.
Expected
The refusal explains old and new values; the new source value appears but cannot execute until confirmed.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/integration/services/merges/approval-binding.integration.spec.js#refuses the approved execution as plan_stale, naming the old value and the new one
08 Workspace labels make preview choices readableruleapitest
Proves
BR-CAP-CRM-DQ-013-10
Preconditions
Prepare referenced types and states including an archived type.
Steps
Read their plan.
Expected
Values use names and archive markings; internal terms and identities do not appear in ordinary preview sentences.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/integration/services/merges/lookup-labels.integration.spec.js#offers the same names as the choices of the conflict, so no choice is drawn from an id
09 Validation returns the current previewtransitionapitest
Proves
BR-CAP-CRM-DQ-013-12
Preconditions
An open plan already holds decisions.
Steps
Request explicit validation.
Expected
The service returns the recomputed plan for current records.
Data
The existing scenario setup supplies the required records.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#answers the validation with the plan as it is now, ready to execute
10 Concurrent decision work fails visibly when staleconcurrencybrowsertest
Proves
BR-CAP-CRM-DQ-013-05 BR-CAP-CRM-DQ-013-07
Preconditions
A preview has several questions.
Steps
Answer separately, clear, submit an unknown question, save an old version and refresh as another administrator.
Expected
Valid answers remain, clear is explicit, invalid answers write nothing and stale changes prompt a reload.
Data
The existing scenario setup supplies the required records.
Bound to
Source
react-console:acceptance/crm/playwright/journeys/merging/CRM-ACC-0249.spec.ts#CRM-ACC-0249
11 Observe needs_decisions becoming ready after answers or current data remove the last required questiontransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-04
Preconditions
Arrange needs_decisions standing with the transition guard satisfied: Changes use a current version and valid participant choices.
Steps
Answers or current data remove the last required question.
Expected
Read the ready standing and inspect the associated changes: persist refreshed preview, material hash and standing.
Data
Fixtures for needs_decisions, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#refuses the execution request as a plan that is not ready
12 Observe ready becoming needs_decisions after changed participants or data introduce an unanswered questiontransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-12
Preconditions
Arrange ready standing with the transition guard satisfied: Recomputation discovers the new conflict.
Steps
Changed participants or data introduce an unanswered question.
Expected
Read the needs_decisions standing and inspect the associated changes: persist the recomputed preview; report decisions that no longer apply.
Data
Fixtures for ready, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/unit/services/planning/merge-decisions.spec.js#is dropped and reported when the plan is simply read again after the data moved on
13 Observe ready becoming blocked after current planning discovers a blocking conditiontransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-12 INV-DOM-CRM-DQ-003-08
Preconditions
Arrange ready standing with the transition guard satisfied: Recomputation identifies a blocker.
Steps
Current planning discovers a blocking condition.
Expected
Read the blocked standing and inspect the associated changes: persist the blocked preview.
Data
Fixtures for ready, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/unit/services/planning/merge-decisions.spec.js#blocks the merge for a column the registry declares no policy for
14 Observe blocked becoming ready after a blocking condition clears and no required question remainstransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-12 INV-DOM-CRM-DQ-003-08
Preconditions
Arrange blocked standing with the transition guard satisfied: No blocker or required unanswered conflict remains.
Steps
A blocking condition clears and no required question remains.
Expected
Read the ready standing and inspect the associated changes: persist the ready preview.
Data
Fixtures for blocked, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#answers the validation with the plan as it is now, ready to execute
15 Observe needs_decisions becoming blocked after planning discovers a blocker before questions are settledtransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-12 INV-DOM-CRM-DQ-003-08
Preconditions
Arrange needs_decisions standing with the transition guard satisfied: Recomputation identifies a blocker.
Steps
Planning discovers a blocker before questions are settled.
Expected
Read the blocked standing and inspect the associated changes: persist the blocked preview.
Data
Fixtures for needs_decisions, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/unit/services/planning/merge-decisions.spec.js#blocks the merge for a column the registry declares no policy for
16 Observe blocked becoming needs_decisions after a blocker clears while unanswered questions remaintransitionapiproposed
Proves
BR-CAP-CRM-DQ-013-12 INV-DOM-CRM-DQ-003-08
Preconditions
Arrange blocked standing with the transition guard satisfied: Recomputation still needs a required answer.
Steps
A blocker clears while unanswered questions remain.
Expected
Read the needs_decisions standing and inspect the associated changes: persist the preview awaiting decisions.
Data
Fixtures for blocked, the guard and the affected records; a fixed clock for time-dependent changes.
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#answers the validation with the plan as it is now, ready to execute
17 A stale answer preserves both saved decisionsinvariantapitest
Proves
INV-DOM-CRM-DQ-003-03
Preconditions
A plan already changed by another administrator.
Steps
Submit an answer at the earlier version and read the saved plan.
Expected
The refusal leaves the current version and both decisions unchanged.
Data
Records, versions and caller contexts owned by the run; transaction failure injection when the invariant concerns rollback.
Bound to
Source
services-crm:modules/merges/tests/integration/services/merges/merge-plan-decisions.integration.spec.js#leaves both decisions on the plan, at the version it was refused against
18 A second answer retains the first answerinvariantapitest
Proves
INV-DOM-CRM-DQ-003-04
Preconditions
A plan with two answerable conflicts.
Steps
Answer the first and then the second in a request naming only that conflict.
Expected
The plan contains both saved answers.
Data
Records, versions and caller contexts owned by the run; transaction failure injection when the invariant concerns rollback.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#keeps the first answer when the second request answers only the other conflict
19 An optional field offers only retained source values or clearinginvariantunittest
Proves
INV-DOM-CRM-DQ-003-05
Preconditions
A preview with two distinct values for one optional field.
Steps
Inspect available choices and submit an invented value.
Expected
The displayed choices are the participant values and clearing; the invented choice is refused.
Data
Records, versions and caller contexts owned by the run; transaction failure injection when the invariant concerns rollback.
Bound to
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#offers clearing the field as well as each value held
Source
services-crm:modules/merges/tests/unit/services/planning/contact-fields.spec.js#offers clearing the field as well as each value held
20 Validation returns the recomputed ready previewinvariantapitest
Proves
INV-DOM-CRM-DQ-003-07
Preconditions
An open preview whose relevant source data has changed.
Steps
Validate and inspect the returned plan and saved preview.
Expected
The response reflects current records and its ready standing is persisted.
Data
Records, versions and caller contexts owned by the run; transaction failure injection when the invariant concerns rollback.
Bound to
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#answers the validation with the plan as it is now, ready to execute
21 Choice recency uses field history before record ageruleapinegativeproposed
Proves
BR-CAP-CRM-DQ-013-11
Preconditions
Two participants with conflicting values, only one carrying a captured change of that field.
Steps
Read the displayed timestamps and defaults, then repeat with neither participant carrying field history.
Expected
The history-backed choice reports its field-change instant; the fallback reports each record’s creation instant.
Data
Run-owned records and caller permissions that distinguish the two cases.
Source
services-crm:modules/merges/tests/e2e/merges.e2e.spec.js#says when each competing value last changed, so a reader can see which is freshest (gap G9)
22 Retained values become the approved execution inputinteractionapiproposed
Proves
BR-CAP-CRM-DQ-013-01 BR-CAP-CRM-DQ-013-02 BR-CAP-CRM-DQ-013-03 BR-CAP-CRM-DQ-013-04 BR-CAP-CRM-DQ-013-05 BR-CAP-CRM-DQ-013-06 BR-CAP-CRM-DQ-013-07 BR-CAP-CRM-DQ-013-08 BR-CAP-CRM-DQ-013-10 BR-CAP-CRM-DQ-013-12 BR-CAP-CRM-DQ-013-11
Preconditions
Run-owned contact and organization records, the relevant staff permissions and the related state described by the sequence.
Steps
Resolve a deceased-status disagreement, clear another answer, validate, then change a source value and submit the previously reviewed preview.
Expected
Validation and stale refusal agree with the named rules and no unapproved value is written.
Data
An isolated workspace with related records and fixed timestamps; owned participant failure injection where requested.
Source
CAP-CRM-DQ-013; CAP-CRM-DQ-014; CAP-CRM-DQ-016; WF-CRM-DQ-005

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.