Test Case Type for software test interface Testing

Source: Internet
Author: User

The purpose of the interface test is to test the interface (which sounds strange), especially those external interfaces associated with the system. The focus of the test is to check the data exchange, transfer, and control management process, it also includes the number of processing times. This article mainly introduces the types of Interface Test Cases. Let's take a look.

AD: wot2014: user tag system and user data operation training session

 

Interface TestIs part of the project test. It tests interfaces and tests interfaces between system components. Interface testing is mainly used to detect the interaction between the external system and the tested system and between the internal systems. The focus of the test is to check the interdependence of data interaction, transfer and control management processes that are expected to be seen by the system.

I recently tested the service-layer interface test and summarized the Interface Test Case types. There are roughly three test types:

1. interface logic test

If you want to ensure the smooth operation of the interface test, it is essential for developers to write and write javadoc. How to test javadoc is not described here. Here we will mainly write test cases based on javadoc, in general, javadoc must contain the description of the prerequisites, business logic, input parameters, and output values. In the interface logic test, the test case is designed based on the described business logic, the main goal is to test that the correct results can be obtained under normal input. The design method of the test case is similar to that of the black box test, mainly using the equivalence class and boundary value methods.

2. Error Test

In the test of interface logic, the main test is the normal logic, that is, the interface service provided externally can work, but these tests cannot ensure data security, and the logic correctness of the program in the abnormal situation. Therefore, you need to test the error test, mainly including the following aspects:

1) null value input. If an object parameter is input, a null value parameter is required.

2) Test the parameter property. If you enter an unassigned Parameter

3) exception testing: Creates abnormal testing scenarios and whether the exception description is clear

4) In addition, for example, the number of parameters and the parameter type (such as the int type input string parameter) error test, because the IDE itself reports compilation error information, the design of the test case can not be performed here.

3. Path Test

After the above processing, a single interface service has been guaranteed, but it is not guaranteed whether the business needs are met in the business flow, the purpose of path testing is to design as few use cases as possible to ensure that data is safe and operable in various business scenarios. An example of a path test case is as follows:

The test cases here include:

1. ABC

2. Abd

3. AE

4. AFG

If the path a contains more than one test interface, you can add the following use cases based on the preceding use cases:

5. A' BC

6. A' BD

7. a' e

8. A' FG

If multiple interfaces such as the C and D paths can be implemented, you can also add use cases based on this method to overwrite the paths. However, there are many combinations of overwrite paths, therefore, in actual situations, we need to design based on actual business scenarios. For example, the path a' BC may not exist in actual business logic, so we do not need to list it here.

A good WebService testing process should be based on the rich demand discussion and document testing in the early stage. The more detailed the requirements are discussed, the smaller the interface architecture changes in the later stage. The more adequate the document test, the higher the interface quality. Through this article, we can understand several Use Cases of interface testing, hoping to help you.
 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.