6 steps in one article take you to get started with interface testing

1. Overview of interface testing

1 What is interface testing:

Interface testing is a type of testing that tests the interaction between system components. Interface testing is mainly used to detect the interaction points between external systems and internal subsystems. The focus of the test is to check the exchange of data, the process of delivery and control management, and the mutual logical dependencies between the systems.

2 Why do interface tests:

Many systems now have separate front-end and back-end architectures. From a security perspective, only relying on the front-end for restrictions can no longer meet the security requirements of the system (it is too easy to bypass the front-end), and the back-end needs to be controlled as well. In this case It needs to be verified from the interface level.

 Nowadays, the system is becoming more and more complex, and the traditional front-end testing has greatly reduced the efficiency, and now we all advocate moving the test forward, hoping that the test can intervene in the test earlier, and the interface test is a way to intervene early. For example, in traditional testing, you have to wait for the front and back ends to be completed before you can test and write automated code. If it is an interface test, only the front and back ends need to define the interface, then automation can intervene at this time, write the interface test automation code, manual testing only needs to complete the back-end code, and then can intervene in the test of the back-end logic without waiting for the front-end work to complete.

2. Interface testing process

 Interface testing is also a functional test, so it is not much different from our previous functional testing process. The testing process is still as follows:

1. Test interface document (requirement document)

2. Write test cases according to interface documents (use case writing can be written according to previous rules, such as equivalence class division, boundary value and other design methods)

3. Execute the test to check whether the data returned by the interface meets expectations for different parameter requests.

3. Interface Test Quality Evaluation Standards

  1. Whether the business function coverage is complete
  2. Whether the business logic is fully covered
  3. Whether the parameter verification meets the requirements (boundary, equivalence class division, business rules)
  4. Whether the coverage of interface exception scenarios is complete (idempotent\anti-heavy, concurrency, environment, large data volume)
  5. Whether the interface coverage meets the requirements (number of covered interfaces/total number of interfaces in the system)
  6. Does the code coverage meet the requirements?
  7. Whether the performance indicators meet the requirements (response time, server resource usage)
  8. Whether the security indicators meet the requirements (encryption of sensitive information, sql injection, unauthorized access)

4. Brain Map

5. Continuous integration of interface testing

For interface testing, continuous integration automation is the core content. Only by means of automation can we achieve low-cost and high-yield. Realizing interface automation is mainly used in the regression stage, and the degree of automation needs to be strengthened in the future, including but not limited to the following:

  1. In terms of process: In the regression stage, the coverage of interface exception scenarios will be strengthened, and gradually extended to the system test and smoke test stages, and finally achieve full process automation.
  2. Result display: richer result display, trend analysis, quality statistics and analysis, etc.
  3. Problem location: Error information and logs are more accurate, making it easier to reproduce and locate problems.
  4. Result verification: strengthen automatic verification capabilities, such as database information verification.
  5. Code coverage: Constantly try to drop from the current black box to the white box to improve code coverage.
  6. Performance requirements: improve the performance testing system, and monitor whether the interface performance indicators are normal through automated means.

6. Interface automation framework

Jmeter+ant+Jenkins

The following is the supporting information. For friends who do [software testing], it should be the most comprehensive and complete preparation warehouse. This warehouse also accompanied me through the most difficult journey. I hope it can help you too!

Software testing interview applet

The software test question bank maxed out by millions of people! ! ! Who is who knows! ! ! The most comprehensive quiz mini program on the whole network, you can use your mobile phone to do the quizzes, on the subway or on the bus, roll it up!

The following interview question sections are covered:

1. Basic theory of software testing, 2. web, app, interface function testing, 3. network, 4. database, 5. linux

6. web, app, interface automation, 7. performance testing, 8. programming basics, 9. hr interview questions, 10. open test questions, 11. security testing, 12. computer basics

Information acquisition method:

Guess you like

Origin blog.csdn.net/jiangjunsss/article/details/131743601