Application program interface testing method and application program interface testing system

An application program interface and test method technology, applied in the field of electrical data processing, can solve the problems of low test efficiency, consumption of manpower, material resources cannot be simulated, etc., to save financial costs, save labor costs, improve effectiveness and test efficiency. Effect

CN107391383AActive Publication Date: 2017-11-24上海巍擎信息技术有限责任公司
14 Cites 10 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Publication Date
2017-11-24

Smart Images

  • Figure 1
    Figure 1
  • Figure 2
    Figure 2
Patent Text Reader

Abstract

The invention provides an application program interface testing method and an application program interface testing system. The application program interface testing method includes: when a UI (user interface) interface of a to-be-tested application program is judged to be first appearance, converting the UI interface into an image; inputting the acquired image into a default UI interface classifier to acquire the type of the UI interface, wherein the UI interface classifier is the UI interface classifier based on a CNN (convolutional neural network); according to the type of the UI interface, acquiring a corresponding test outline script from a default test outline script library; subjecting the test outline script and the layout of the UI interface to matching to acquire a test script corresponding to the UI interface; testing the UI interface through the test script. The type of the UI interface and the test outline script are acquired through the CNN based UI interface classifier, the classification result can be similar to the classification result of an ordinary user, the automatic test step is close to the operation process of the user, and test scenario validity and test efficiency are greatly improved.
Need to check novelty before this filing date? Find Prior Art

Description

technical field

[0001] The invention belongs to the field of electric data processing, and in particular relates to a testing method and a testing system of an application program interface. Background technique

[0002] Applications often determine their usefulness and security through testing of their interfaces. The existing technology usually uses manual and automated testing methods when testing the application program interface: artificially means that people test the application program interface, which will consume a lot of labor costs; automated testing is to test each type of application program Write corresponding test scripts to realize automated testing of the application program interface through test scripts, but writing test scripts for each type of application not only consumes labor costs, but also consumes material resources. In addition, the traversal tools for automated testing generally use depth-first or breadth-first logic for testing. First, collect...

Examples

Embodiment 1

[0023] like figure 1 Shown is a flow chart of a testing method for an application program interface shown in an exemplary embodiment of the present invention, and the testing method includes the following steps:

[0024] Step S101, when it is determined that the acquired UI interface of the application program to be tested appears for the first time, convert the UI interface into a picture.

[0025] In the embodiment of the present invention, the application program interface is usually expressed by a UI interface, and the application program to be tested can be scanned by a preset automatic scanning tool during testing. Preferably, the automatic scanning tool is an automatic scanning tool made by Python, such as using Python to write test logic on the open source testing tool Appium to test the application programs of Andorid and IOS. It can be understood that the application program to be tested includes but is not limited to: mobile terminal application program and non-mob...