Writing Comprehensive Test Cases: Functional and Non‑Functional Testing Guidelines
This article explains how to create thorough test cases by outlining their purpose, covering functional aspects such as CRUD, GUI validation, data accuracy, business logic, backend checks, concurrency, and non‑functional concerns like browser compatibility, stress, API testing, and security, while emphasizing the need for project‑specific customization.
For professional testers, writing test cases is familiar, but creating highly covering test cases requires careful thought.
The article first asks why test cases exist and for whom they are written, answering that test cases are derivatives of product prototypes, written for anyone who wants to understand the system and updated as the prototype evolves.
It stresses that understanding a system often comes from analyzing requirements rather than extracting from existing cases, and that strong coverage ensures system robustness.
Test cases are broadly divided into functional and non‑functional testing.
Functional testing points include:
CRUD operations as the foundation.
GUI page checks and element validation across PC, Android, iOS, covering character limits, illegal inputs, required fields, prompts, dialogs, and collections.
Data accuracy, focusing on lifecycle verification and initial data handling.
Business logic correctness, ensuring end‑user experience aligns with product intent.
Backend special validations such as file upload/download and duplicate handling (e.g., phone number import scenarios).
Business correlation, exemplified by ES data synchronization across services.
Concurrent operations, reproduced by using two browsers to edit the same data simultaneously.
Non‑functional testing considerations mentioned are:
Browser compatibility, selecting 2‑3 major browsers for focused testing.
Stress testing, performed based on expected user load.
API testing when UI cannot perform CRUD operations.
Security and risk assessment, depending on project needs.
The article also notes the importance of test case review, updates, and continuous improvement, concluding that test cases should be tailored to each project rather than copied, using the discussed points as a reference to achieve the testing goal of uncovering program errors.
360 Quality & Efficiency
360 Quality & Efficiency focuses on seamlessly integrating quality and efficiency in R&D, sharing 360’s internal best practices with industry peers to foster collaboration among Chinese enterprises and drive greater efficiency value.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.