Admin CRM — Setting Service Test Cases
A. Document controlA. Kiểm soát tài liệu
| Doc ID | CPG-TC-CPG-CRM_Setting_Service_TestCases |
|---|---|
| VersionPhiên bản | 1.0 |
| StatusTrạng thái | Draft |
| Owner | CPG BA / Architecture |
| AudienceĐối tượng | QA, Product, Backend, Frontend |
| ClassificationPhân loại | Internal |
| Effective dateNgày hiệu lực | 01/12/2026 |
| Related docs | CRM Setting Service UC · CRM Setting Service FSD |
B. Version historyB. Lịch sử phiên bản
| Version | Date | Author | ChangesThay đổi |
|---|---|---|---|
| 1.0 | 01/12/2026 | Khoa Trinh | Version 1.0 |
C. Table of contentsC. Mục lục
D. ContentD. Nội dung
Index
| Test ID | Test name | BR | UC | Category |
|---|---|---|---|---|
| QR-001 | View QR Payment card in Service Management | 3.1.1 |
UC-SVC-01 | Function |
| QR-002 | Filter by Tier shows only services applicable to tier | 3.1.1 |
UC-SVC-01 | Function |
| QR-003 | Search service by name | 3.1.1 |
UC-SVC-01 | Function |
| QR-004 | Service card shows blockchain chips for enabled chains | 3.1.1 |
UC-SVC-01 | Function |
| QR-005 | Fees by chain displayed correctly on service card | 3.1.1 |
UC-SVC-01 | Function |
| QR-006 | Toggle service status when NOT deployed (direct mode) | 3.1.6 |
UC-SVC-04 | Function |
| QR-007 | Toggle service status when deployed triggers proposal flow | 3.1.6 |
UC-SVC-04 | Function |
| QR-008 | Toggle service status when deployed cannot bypass via direct API | 3.1.6 |
UC-SVC-04 | Security |
| QR-009 | Open Edit Service from card | 3.1.2 |
UC-SVC-01 | Function |
| QR-010 | Cancel button discards changes | 3.1.2 |
UC-SVC-01 | Function |
| QR-011 | Update Service saves successfully | 3.1.2 |
UC-SVC-01 | Function |
| QR-012 | Required field validation: Service Name | 3.1.2 |
UC-SVC-01 | Validation |
| QR-013 | Required field validation: Description (if required) | 3.1.2 |
UC-SVC-01 | Validation |
| QR-014 | Enable a blockchain (checkbox) | 3.1.3 |
UC-SVC-02 | Function |
| QR-015 | Disable a blockchain removes fee section | 3.1.3 |
UC-SVC-02 | Function |
| QR-016 | Fees accept decimal tx fee (%) | 3.1.3 |
UC-SVC-02 | Function |
| QR-017 | Fees accept fixed fee amount | 3.1.3 |
UC-SVC-02 | Function |
| QR-018 | Tx fee validation: negative % rejected | 3.1.3 |
UC-SVC-02 | Validation |
| QR-019 | Tx fee validation: over max % rejected | 3.1.3 |
UC-SVC-02 | Validation |
| QR-020 | Fixed fee validation: negative rejected | 3.1.3 |
UC-SVC-02 | Validation |
| QR-021 | Empty fee fields handling | 3.1.3 |
UC-SVC-02 | Validation |
| QR-022 | Multiple chain fee sections persist correctly | 3.1.3 |
UC-SVC-02 | Function |
| QR-023 | Features field accepts comma-separated values | 3.1.5 |
UC-SVC-01 | Function |
| QR-024 | Features trims spaces and removes empty items | 3.1.5 |
UC-SVC-01 | Validation |
| QR-025 | Features supports unicode | 3.1.5 |
UC-SVC-01 | Function |
| QR-026 | Prevent lost update via versioning | 3.1.2 |
UC-SVC-01 | Function |
| QR-027 | Read-only user cannot edit service | 3.1.2 |
UC-SVC-01 | Security |
| QR-028 | User without approve cannot approve proposals | 3.1.6 |
UC-SVC-04 | Function |
| QR-029 | Reject proposal with reason | 3.1.6 |
UC-SVC-04 | Function |
| QR-030 | Apply approved proposal changes service status | 3.1.6 |
UC-SVC-04 | Function |
| QR-031 | Deactivation mode HARD blocks immediate usage | 3.1.6 |
UC-SVC-04 | Function |
| QR-032 | Audit log created for proposal submit | 3.1.6 |
UC-SVC-04 | Audit |
| QR-033 | Audit log created for status applied | 3.1.6 |
UC-SVC-04 | Audit |
Test cases
QR-001
| Field | Value |
|---|---|
| Test ID | QR-001 |
| Business Requirement ID | 3.1.1 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | View QR Payment card in Service Management |
| Preconditions | Login as Admin; QR Payment exists |
| Data | N/A |
| Steps | Open System > Services > Crypto Payment |
| Expected result | QR Payment card visible with name, type=Crypto, status chip, tier chip, blockchains chips, fees by chain shown |
QR-002
| Field | Value |
|---|---|
| Test ID | QR-002 |
| Business Requirement ID | 3.1.1 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Filter by Tier shows only services applicable to tier |
| Preconditions | Services have tier mapping |
| Data | Tier=Basic |
| Steps | Select "Filter by Tier = Basic" |
| Expected result | List shows services compatible with Basic tier; QR Payment shown if mapped to Basic |
QR-003
| Field | Value |
|---|---|
| Test ID | QR-003 |
| Business Requirement ID | 3.1.1 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Search service by name |
| Preconditions | QR Payment exists |
| Data | "QR" |
| Steps | Use search input (if available) / scroll |
| Expected result | QR Payment appears in results |
QR-004
| Field | Value |
|---|---|
| Test ID | QR-004 |
| Business Requirement ID | 3.1.1 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Service card shows blockchain chips for enabled chains |
| Preconditions | QR Payment configured with chains |
| Data | Tron/Ethereum/BSC/Polygon enabled |
| Steps | Open Services list |
| Expected result | Chips displayed for enabled chains only |
QR-005
| Field | Value |
|---|---|
| Test ID | QR-005 |
| Business Requirement ID | 3.1.1 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Fees by chain displayed correctly on service card |
| Preconditions | QR Payment has fees per chain |
| Data | Tron tx=1.5 fixed=0 |
| Steps | Compare card values with backend/config |
| Expected result | Card shows correct transaction % and fixed fee for each enabled chain |
QR-006
| Field | Value |
|---|---|
| Test ID | QR-006 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | Toggle service status when NOT deployed (direct mode) |
| Preconditions | QR Payment is NOT deployed; is_deployed=false |
| Data | Toggle ON/OFF |
| Steps | Toggle Service Status switch on card |
| Expected result | Status changes immediately; success toast; status persists after refresh |
QR-007
| Field | Value |
|---|---|
| Test ID | QR-007 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | Toggle service status when deployed triggers proposal flow |
| Preconditions | QR Payment deployed/used; is_deployed=true |
| Data | Request deactivate |
| Steps | Toggle Service Status switch OFF |
| Expected result | System blocks direct change; shows "Proposal required" and opens proposal creation (or prompts to create) |
QR-008
| Field | Value |
|---|---|
| Test ID | QR-008 |
| Business Requirement ID | 3.1.6 |
| Category | Security |
| Use Case ID | UC-SVC-04 |
| Test name | Toggle service status when deployed cannot bypass via direct API |
| Preconditions | is_deployed=true |
| Data | PATCH /status |
| Steps | Call direct status endpoint |
| Expected result | API returns 409/422 "Proposal required"; status unchanged |
QR-009
| Field | Value |
|---|---|
| Test ID | QR-009 |
| Business Requirement ID | 3.1.2 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Open Edit Service from card |
| Preconditions | QR Payment exists |
| Data | N/A |
| Steps | Click edit (pencil) on QR Payment card |
| Expected result | Edit Service page opens with prefilled data |
QR-010
| Field | Value |
|---|---|
| Test ID | QR-010 |
| Business Requirement ID | 3.1.2 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Cancel button discards changes |
| Preconditions | Edit page was opened |
| Data | Change name |
| Steps | Edit fields; click Cancel |
| Expected result | Modal closes; changes not saved |
QR-011
| Field | Value |
|---|---|
| Test ID | QR-011 |
| Business Requirement ID | 3.1.2 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Update Service saves successfully |
| Preconditions | Permissions: write service |
| Data | Name updated |
| Steps | Change description; click Update Service |
| Expected result | Success message; card reflects new description after refresh |
QR-012
| Field | Value |
|---|---|
| Test ID | QR-012 |
| Business Requirement ID | 3.1.2 |
| Category | Validation |
| Use Case ID | UC-SVC-01 |
| Test name | Required field validation: Service Name |
| Preconditions | Edit page was opened |
| Data | Empty name |
| Steps | Clear Service Name; click Update |
| Expected result | Validation message; save blocked |
QR-013
| Field | Value |
|---|---|
| Test ID | QR-013 |
| Business Requirement ID | 3.1.2 |
| Category | Validation |
| Use Case ID | UC-SVC-01 |
| Test name | Required field validation: Description (if required) |
| Preconditions | Edit page was opened |
| Data | Empty description |
| Steps | Clear Description; click Update |
| Expected result | Validation shown; save blocked (if description mandatory) |
QR-014
| Field | Value |
|---|---|
| Test ID | QR-014 |
| Business Requirement ID | 3.1.3 |
| Category | Function |
| Use Case ID | UC-SVC-02 |
| Test name | Enable a blockchain (checkbox) |
| Preconditions | Edit page was opened |
| Data | Enable Polygon |
| Steps | Check Polygon |
| Expected result | Chain section appears for Polygon fee inputs; chip appears after save |
QR-015
| Field | Value |
|---|---|
| Test ID | QR-015 |
| Business Requirement ID | 3.1.3 |
| Category | Function |
| Use Case ID | UC-SVC-02 |
| Test name | Disable a blockchain removes fee section |
| Preconditions | Edit page was opened; chain enabled |
| Data | Disable BSC |
| Steps | Uncheck BSC |
| Expected result | BSC fee section hidden; after save, chip removed; fees not displayed |
QR-016
| Field | Value |
|---|---|
| Test ID | QR-016 |
| Business Requirement ID | 3.1.3 |
| Category | Function |
| Use Case ID | UC-SVC-02 |
| Test name | Fees accept decimal tx fee (%) |
| Preconditions | Edit page was opened |
| Data | tx_fee=1.5 |
| Steps | Enter 1.5 in Transaction Fee (%) |
| Expected result | Value accepted; stored; displayed correctly |
QR-017
| Field | Value |
|---|---|
| Test ID | QR-017 |
| Business Requirement ID | 3.1.3 |
| Category | Function |
| Use Case ID | UC-SVC-02 |
| Test name | Fees accept fixed fee amount |
| Preconditions | Edit page was opened |
| Data | fixed_fee=0 |
| Steps | Enter 0 |
| Expected result | Value accepted; stored; displayed correctly |
QR-018
| Field | Value |
|---|---|
| Test ID | QR-018 |
| Business Requirement ID | 3.1.3 |
| Category | Validation |
| Use Case ID | UC-SVC-02 |
| Test name | Tx fee validation: negative % rejected |
| Preconditions | Edit page was opened |
| Data | -1.0 |
| Steps | Enter -1 in tx fee; save |
| Expected result | Validation error; save blocked |
QR-019
| Field | Value |
|---|---|
| Test ID | QR-019 |
| Business Requirement ID | 3.1.3 |
| Category | Validation |
| Use Case ID | UC-SVC-02 |
| Test name | Tx fee validation: over max % rejected |
| Preconditions | Edit page was opened |
| Data | 1000.0 |
| Steps | Enter 1000; save |
| Expected result | Validation error; save blocked |
QR-020
| Field | Value |
|---|---|
| Test ID | QR-020 |
| Business Requirement ID | 3.1.3 |
| Category | Validation |
| Use Case ID | UC-SVC-02 |
| Test name | Fixed fee validation: negative rejected |
| Preconditions | Edit page was opened |
| Data | -10.0 |
| Steps | Enter -10 fixed fee; save |
| Expected result | Validation error; save blocked |
QR-021
| Field | Value |
|---|---|
| Test ID | QR-021 |
| Business Requirement ID | 3.1.3 |
| Category | Validation |
| Use Case ID | UC-SVC-02 |
| Test name | Empty fee fields handling |
| Preconditions | Edit page was opened |
| Data | empty |
| Steps | Clear tx fee and fixed fee; save |
| Expected result | Either: defaults applied OR validation shown (per rule). No silent corruption |
QR-022
| Field | Value |
|---|---|
| Test ID | QR-022 |
| Business Requirement ID | 3.1.3 |
| Category | Function |
| Use Case ID | UC-SVC-02 |
| Test name | Multiple chain fee sections persist correctly |
| Preconditions | Edit page was opened |
| Data | Tron=1.5, ETH=1.5, BSC=1.5 |
| Steps | Set different values per chain; save |
| Expected result | Each chain retains its own fee values; card shows correct per chain |
QR-023
| Field | Value |
|---|---|
| Test ID | QR-023 |
| Business Requirement ID | 3.1.5 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Features field accepts comma-separated values |
| Preconditions | Modal open |
| Data | "Instant generation, Mobile optimized" |
| Steps | Enter features; save |
| Expected result | Features stored as list; displayed as tags on card (if UI shows tags) |
QR-024
| Field | Value |
|---|---|
| Test ID | QR-024 |
| Business Requirement ID | 3.1.5 |
| Category | Validation |
| Use Case ID | UC-SVC-01 |
| Test name | Features trims spaces and removes empty items |
| Preconditions | Modal open |
| Data | "A, , B ," |
| Steps | Enter and save |
| Expected result | Stored list becomes [A,B]; no empty tags |
QR-025
| Field | Value |
|---|---|
| Test ID | QR-025 |
| Business Requirement ID | 3.1.5 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Features supports unicode |
| Preconditions | Modal open |
| Data | Create QR quickly"Tạo QR nhanh" |
| Steps | Enter features; save |
| Expected result | Saved and displayed correctly |
QR-026
| Field | Value |
|---|---|
| Test ID | QR-026 |
| Business Requirement ID | 3.1.2 |
| Category | Function |
| Use Case ID | UC-SVC-01 |
| Test name | Prevent lost update via versioning |
| Preconditions | Two admins open same service |
| Data | Admin A & B |
| Steps | A changes description and saves; B changes tx fee and saves |
| Expected result | System either merges safely or rejects B with conflict error requiring reload |
QR-027
| Field | Value |
|---|---|
| Test ID | QR-027 |
| Business Requirement ID | 3.1.2 |
| Category | Security |
| Use Case ID | UC-SVC-01 |
| Test name | Read-only user cannot edit service |
| Preconditions | Role lacks write permission |
| Data | N/A |
| Steps | Login as read-only; open modal |
| Expected result | Edit actions disabled; Update button hidden/disabled |
QR-028
| Field | Value |
|---|---|
| Test ID | QR-028 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | User without approve cannot approve proposals |
| Preconditions | Deployed service; proposal exists |
| Data | N/A |
| Steps | Try approve proposal |
| Expected result | Access denied; proposal unchanged |
QR-029
| Field | Value |
|---|---|
| Test ID | QR-029 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | Reject proposal with reason |
| Preconditions | Proposal SUBMITTED/UNDER_REVIEW |
| Data | rejected_reason |
| Steps | Reject action |
| Expected result | Proposal status REJECTED; reason stored; service status unchanged |
QR-030
| Field | Value |
|---|---|
| Test ID | QR-030 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | Apply approved proposal changes service status |
| Preconditions | Proposal APPROVED |
| Data | Apply |
| Steps | Apply proposal |
| Expected result | Service status updated; proposal status APPLIED; audit log created |
QR-031
| Field | Value |
|---|---|
| Test ID | QR-031 |
| Business Requirement ID | 3.1.6 |
| Category | Function |
| Use Case ID | UC-SVC-04 |
| Test name | Deactivation mode HARD blocks immediate usage |
| Preconditions | is_deployed=true |
| Data | HARD |
| Steps | Create + approve + apply |
| Expected result | Service becomes inactive immediately; merchants cannot initiate new QR payments |
QR-032
| Field | Value |
|---|---|
| Test ID | QR-032 |
| Business Requirement ID | 3.1.6 |
| Category | Audit |
| Use Case ID | UC-SVC-04 |
| Test name | Audit log created for proposal submit |
| Preconditions | Proposal submitted |
| Data | N/A |
| Steps | Submit proposal |
| Expected result | Audit log entry STATUS_CHANGE_REQUESTED exists with actor and timestamp |
QR-033
| Field | Value |
|---|---|
| Test ID | QR-033 |
| Business Requirement ID | 3.1.6 |
| Category | Audit |
| Use Case ID | UC-SVC-04 |
| Test name | Audit log created for status applied |
| Preconditions | Proposal applied |
| Data | N/A |
| Steps | Apply proposal |
| Expected result | Audit log entry STATUS_CHANGED exists, references proposal |