How to write efficient software test cases? Two hours on using the case, one whole day on fishing

To write efficient test cases, you need to understand what a test case is and how to write efficient test cases? Next, we will expand on the following parts:

1. What is a test case
2. How to write a test case
3. Sharing of special learning resources for test cases

1. What is a test case?

Test case: A document composed of a set of test inputs, execution conditions, and expected results designed for a specific purpose.

A simple understanding is to split the product requirements into functional points, and then verify their correctness.

2. How to write test cases

There are two main ways to write test cases:

  • Cover all test points of requirements
  • Discover test points beyond requirements

Below we will explain how to implement it:

1. See how to achieve coverage of all test points required

1) Able to understand requirements documents and find accurate test basis

As a tester, requirements documents are the basis for testing software . You first need to understand the product requirements documents . The test points involved in the requirements document can be sorted out. A simple understanding is the process of converting large paragraphs of text descriptions into mind maps. It is recommended that you organize them in the form of Xmind.

Secondly, on the basis of the requirements document, combined with the testing environment or product personnel, to deepen the understanding of the requirements , facilitate subsequent better familiarity with the requirements, organize test points and write use cases.

2) Organize test points

The advantage of organizing test points is to provide a comprehensive and reliable idea for those who write use cases to prevent omissions or errors in the design of use cases. At the same time, it can also reduce the difficulty of writing use cases directly with the requirement text. The purpose of writing is to at least ensure that the requirements are covered .

Convert the requirements in the requirements document into test points to facilitate writing test cases. Generally, the requirements document is divided into small function points and verified separately. Split it down to the point where you can directly write use cases. In this process, you can use some methods of designing use cases, that is, verify each small test purpose separately.

For example, the current page login function requirements are as follows:

If the appeal needs to be split into test points, it can be made as follows:

2. Excavate test points outside of requirements

Before talking about this topic, I need to give you a concept in advance: quality model characteristics.

Quality model features include: functionality, performance efficiency, security, ease of use, compatibility, reliability, etc.

Taking the login function above as an example, according to the quality model characteristics, we can get the out-of-demand test points as follows:

Covering the test points in the requirements is the most basic requirement. On this basis, it is also necessary to explore test points outside the requirements . You can think about it with the help of the characteristics of the software quality model, and try to think more about various possible problems that may exist in the user's use process. kind of scene. For example, the above login function can be designed from a non-functional perspective:

3. Provide special videos on test cases for everyone to learn from

In short, on the basis of confirming the coverage requirements, we should think and supplement through the characteristics of the quality model. The process of using the quality model proficiently is actually expanded and supplemented on the basis of being familiar with the system. Of course, this process can rely on the discussion and review of internal testers. Supplements will be more complete.

   Summarize

If you have any questions about this article, if you also need practical experience in interface projects, if you are interested in software testing, interface testing, automated testing, and interview experience exchange, please join us. The joining method is at the end of the article.

  Recommended tutorials related to automated testing:

The latest automated testing self-study tutorial in 2023 is the most detailed tutorial for newbies to get started in 26 days. Currently, more than 300 people have joined major companies by studying this tutorial! ! _bilibili_bilibili

2023 latest collection of Python automated test development framework [full stack/practical/tutorial] collection essence, annual salary after learning 40W+_bilibili_bilibili

Recommended tutorials related to test development

The best in the entire network in 2023, the Byte test and development boss will give you on-site teaching and teach you to become a test and development engineer with an annual salary of one million from scratch_bilibili_bilibili

postman/jmeter/fiddler test tool tutorial recommendation

The most detailed collection of practical tutorials on JMeter interface testing/interface automated testing projects. A set of tutorials for learning jmeter interface testing is enough! ! _bilibili_bilibili

To teach yourself how to capture packets with fiddler in 2023, please be sure to watch the most detailed video tutorial on the Internet [How to Learn to Capture Packets with Fiddler in 1 Day]! ! _bilibili_bilibili

In 2023, the whole network will be honored. The most detailed practical teaching of Postman interface testing at Station B can be learned by novices_bilibili_bilibili

  Summarize:

 Optical theory is useless. You must learn to follow along and practice it in order to apply what you have learned to practice. At this time, you can learn from some practical cases.

If it is helpful to you, please like and save it to give the author an encouragement. It also makes it easier for you to search quickly next time.

If you don’t understand, please consult the small card below. The blogger also hopes to learn and improve with like-minded testers.

At the appropriate age, choose the appropriate position and try to give full play to your own advantages.

My path to automated test development is inseparable from plans at each stage, because I like planning and summarizing.

Test development video tutorials and study notes collection portal! !

Guess you like

Origin blog.csdn.net/m0_70618214/article/details/135230522