CN116303071A - An interface testing method, device, electronic equipment and storage medium - Google Patents
An interface testing method, device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN116303071A CN116303071A CN202310324598.9A CN202310324598A CN116303071A CN 116303071 A CN116303071 A CN 116303071A CN 202310324598 A CN202310324598 A CN 202310324598A CN 116303071 A CN116303071 A CN 116303071A
- Authority
- CN
- China
- Prior art keywords
- interface
- information
- tested
- test
- data processing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3668—Testing of software
- G06F11/3672—Test management
- G06F11/3676—Test management for coverage analysis
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Hardware Design (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Debugging And Monitoring (AREA)
Abstract
Description
技术领域technical field
本发明实施例涉及计算机技术领域,尤其涉及一种接口测试方法、装置、电子设备及存储介质。The embodiments of the present invention relate to the field of computer technology, and in particular to an interface testing method, device, electronic equipment and storage medium.
背景技术Background technique
在现有的软件系统中可以包括多个接口,例如登录接口或搜索接口等,每个接口可以对应执行不同的功能。在软件系统开发完成之后,通常需要对软件系统中的各个接口进行测试,以通过接口反馈的响应数据判断接口的功能是否正常。An existing software system may include multiple interfaces, such as a login interface or a search interface, and each interface may correspondingly perform different functions. After the development of the software system is completed, it is usually necessary to test each interface in the software system, so as to determine whether the function of the interface is normal through the response data fed back by the interface.
然而,现有的接口测试通常是采用等价类、边界值或错误推测法等算法生成测试用例脚本,或由测试人员人工编写测试用例脚本,以通过测试用例脚本对接口进行测试。但是上述方法往往会出现测试数据不全面的情况,也即遗漏测试场景,从而导致测试场景覆盖率较低,而且测试过程耗时较长,从而导致测试效率较低。However, the existing interface testing usually uses algorithms such as equivalence class, boundary value or error guessing to generate test case scripts, or manually writes test case scripts by testers to test the interface through test case scripts. However, the above methods often have incomplete test data, that is, missing test scenarios, resulting in low coverage of test scenarios, and the test process takes a long time, resulting in low test efficiency.
发明内容Contents of the invention
本发明实施例提供一种接口测试方法、装置、电子设备及存储介质,能够提高接口测试的测试效率以及测试场景的覆盖率,从而提高了接口的有效性和稳定性。The embodiments of the present invention provide an interface testing method, device, electronic equipment, and storage medium, which can improve the testing efficiency of the interface testing and the coverage rate of the testing scenarios, thereby improving the effectiveness and stability of the interface.
根据本发明的一方面,提供了一种接口测试方法,包括:According to an aspect of the present invention, a kind of interface testing method is provided, comprising:
获取待测试接口信息,并根据所述待测试接口信息确定待测试接口;Obtaining the information of the interface to be tested, and determining the interface to be tested according to the information of the interface to be tested;
根据所述待测试接口信息确定所述待测试接口对应的目标接口信息,并对所述目标接口信息进行信息数据处理;determining target interface information corresponding to the to-be-tested interface according to the to-be-tested interface information, and performing information data processing on the target interface information;
根据信息数据处理结果对所述待测试接口进行接口测试。An interface test is performed on the interface to be tested according to the information data processing result.
根据本发明的另一方面,提供了一种接口测试装置,包括:According to another aspect of the present invention, an interface testing device is provided, comprising:
待测试接口确定模块,用于获取待测试接口信息,并根据所述待测试接口信息确定待测试接口;a module to determine the interface to be tested, configured to obtain information on the interface to be tested, and determine the interface to be tested according to the information on the interface to be tested;
信息数据处理模块,用于根据所述待测试接口信息确定所述待测试接口对应的目标接口信息,并对所述目标接口信息进行信息数据处理;An information data processing module, configured to determine target interface information corresponding to the interface to be tested according to the information of the interface to be tested, and perform information data processing on the target interface information;
接口测试模块,用于根据信息数据处理结果对所述待测试接口进行接口测试An interface testing module, configured to perform an interface test on the interface to be tested according to the information and data processing results
根据本发明的另一方面,提供了一种电子设备,所述电子设备包括:According to another aspect of the present invention, an electronic device is provided, and the electronic device includes:
至少一个处理器;以及at least one processor; and
与所述至少一个处理器通信连接的存储器;其中,a memory communicatively coupled to the at least one processor; wherein,
所述存储器存储有可被所述至少一个处理器执行的计算机程序,所述计算机程序被所述至少一个处理器执行,以使所述至少一个处理器能够执行本发明任一实施例所述的接口测试方法。The memory stores a computer program that can be executed by the at least one processor, and the computer program is executed by the at least one processor, so that the at least one processor can execute the method described in any embodiment of the present invention. Interface test method.
根据本发明的另一方面,提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机指令,所述计算机指令用于使处理器执行时实现本发明任一实施例所述的接口测试方法。According to another aspect of the present invention, a computer-readable storage medium is provided, the computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a processor to implement any of the embodiments of the present invention when executed. The interface test method.
本发明实施例的技术方案,通过获取待测试接口信息,并根据待测试接口信息确定待测试接口,以根据待测试接口信息确定待测试接口对应的目标接口信息,并对目标接口信息进行信息数据处理,从而根据信息数据处理结果对待测试接口进行接口测试,解决了现有技术中由于测试数据不全面和测试耗时长导致的测试场景覆盖率低和测试效率低的问题,能够提高接口测试的测试效率以及测试场景的覆盖率,从而提高了接口的有效性和稳定性。In the technical solution of the embodiment of the present invention, by obtaining the information of the interface to be tested, and determining the interface to be tested according to the information of the interface to be tested, the target interface information corresponding to the interface to be tested is determined according to the information of the interface to be tested, and the information data of the target interface information is determined. processing, so that the interface test is performed on the interface to be tested according to the information data processing results, which solves the problems of low test scenario coverage and low test efficiency in the prior art due to incomplete test data and long test time, and can improve the test performance of the interface test. Efficiency and coverage of test scenarios, thereby improving the effectiveness and stability of the interface.
应当理解,本部分所描述的内容并非旨在标识本发明的实施例的关键或重要特征,也不用于限制本发明的范围。本发明的其它特征将通过以下的说明书而变得容易理解。It should be understood that the content described in this section is not intended to identify key or important features of the embodiments of the present invention, nor is it intended to limit the scope of the present invention. Other features of the present invention will be easily understood from the following description.
附图说明Description of drawings
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings that need to be used in the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For those skilled in the art, other drawings can also be obtained based on these drawings without creative effort.
图1是本发明实施例一提供的一种接口测试方法的流程图;FIG. 1 is a flowchart of an interface testing method provided by Embodiment 1 of the present invention;
图2是本发明实施例二提供的一种接口测试方法的流程图;FIG. 2 is a flow chart of an interface testing method provided by Embodiment 2 of the present invention;
图3是本发明实施例二提供的一种接口测试方法的示例流程图;Fig. 3 is an exemplary flow chart of an interface testing method provided in Embodiment 2 of the present invention;
图4是本发明实施例二提供的一种接口测试界面的示意图;Fig. 4 is a schematic diagram of an interface test interface provided by Embodiment 2 of the present invention;
图5是本发明实施例二提供的另一种接口测试界面的示意图;Fig. 5 is a schematic diagram of another interface test interface provided by Embodiment 2 of the present invention;
图6是本发明实施例三提供的一种接口测试装置的示意图;FIG. 6 is a schematic diagram of an interface testing device provided in Embodiment 3 of the present invention;
图7是实现本发明实施例的接口测试方法的电子设备的结构示意图。Fig. 7 is a schematic structural diagram of an electronic device implementing an interface testing method according to an embodiment of the present invention.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分的实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本发明保护的范围。In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only It is an embodiment of a part of the present invention, but not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts shall fall within the protection scope of the present invention.
需要说明的是,本发明的说明书和权利要求书及上述附图中的术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。It should be noted that the terms "comprising" and "having" in the description and claims of the present invention and the above drawings, as well as any variations thereof, are intended to cover a non-exclusive inclusion, for example, including a series of steps or units A process, method, system, product or device is not necessarily limited to those steps or elements explicitly listed, but may include other steps or elements not explicitly listed or inherent to the process, method, product or device.
实施例一Embodiment one
图1是本发明实施例一提供的一种接口测试方法的流程图,本实施例可适用于提高接口测试的测试效率以及测试场景的覆盖率的情况,该方法可以由接口测试装置执行,该装置可以通过软件和/或硬件的方式实现,并一般可以直接集成在执行本方法的电子设备中,该电子设备可以是终端设备,也可以是服务器设备,本发明实施例并不对执行接口测试方法的电子设备的类型进行限定。具体的,如图1所示,该接口测试方法具体可以包括如下步骤:Fig. 1 is a flow chart of an interface testing method provided by Embodiment 1 of the present invention. This embodiment is applicable to the situation of improving the test efficiency of interface testing and the coverage of test scenarios, and the method can be executed by an interface testing device. The device can be implemented by means of software and/or hardware, and generally can be directly integrated into the electronic device that executes the method. The electronic device can be a terminal device or a server device. The embodiment of the present invention does not apply to the implementation of the interface test method The type of electronic equipment is limited. Specifically, as shown in Figure 1, the interface testing method may specifically include the following steps:
S110、获取待测试接口信息,并根据所述待测试接口信息确定待测试接口。S110. Acquire the information of the interface to be tested, and determine the interface to be tested according to the information of the interface to be tested.
其中,待测试接口可以是等待测试的任意接口。待测试接口信息可以是待测试接口的任意信息,例如可以是待测试接口的接口名称信息,也可以是待测试接口的接口请求地址信息,也可以是待测试接口的接口请求方法信息,或者还可以是待测试接口的接口请求参数信息等,本发明实施例对此并不进行限制。Wherein, the interface to be tested may be any interface waiting to be tested. The information of the interface to be tested can be any information of the interface to be tested, such as the interface name information of the interface to be tested, the interface request address information of the interface to be tested, the interface request method information of the interface to be tested, or It may be the interface request parameter information of the interface to be tested, etc., which is not limited in this embodiment of the present invention.
在本发明实施例中,获取待测试接口信息,以根据待测试接口信息确定待测试接口。可以理解的是,软件系统在开发完成后,需要对软件系统中的所有接口进行测试,在所有接口都通过测试之后才可以将软件系统上线。而且在软件系统上线后,也即软件系统的应用过程中,也可以对软件系统中的任意接口进行测试,以确保软件系统的正常运行。In the embodiment of the present invention, the information of the interface to be tested is acquired, so as to determine the interface to be tested according to the information of the interface to be tested. It is understandable that after the development of the software system is completed, all interfaces in the software system need to be tested, and the software system can only be launched after all interfaces pass the test. Moreover, after the software system is launched, that is, during the application process of the software system, any interface in the software system can also be tested to ensure the normal operation of the software system.
S120、根据所述待测试接口信息确定所述待测试接口对应的目标接口信息,并对所述目标接口信息进行信息数据处理。S120. Determine target interface information corresponding to the to-be-tested interface according to the to-be-tested interface information, and perform information data processing on the target interface information.
其中,目标接口信息可以是待测试接口对应的待测试接口信息中的目标信息。信息数据处理可以是对目标接口信息进行数据处理,例如可以是对目标接口信息进行数据解析,也可以是对目标接口信息进行数据替换,或者还可以是对目标接口信息进行数据修改等,本发明实施例对此并不进行限制。Wherein, the target interface information may be the target information in the information of the interface to be tested corresponding to the interface to be tested. The information data processing can be data processing on the target interface information, for example, it can be data analysis on the target interface information, data replacement on the target interface information, or data modification on the target interface information, etc. The present invention The embodiment does not limit this.
在本发明实施例中,在根据待测试接口信息确定待测试接口之后,可以进一步根据待测试接口信息确定待测试接口对应的目标接口信息,以对目标接口信息进行信息数据处理。可以理解的是,目标接口信息可以是待测试接口信息中的一个或多个,本发明实施例对此并不进行限制。另一可以理解的是,不同的目标接口信息,可以对应不同的信息数据处理。In the embodiment of the present invention, after the interface to be tested is determined according to the information of the interface to be tested, the target interface information corresponding to the interface to be tested may be further determined according to the information of the interface to be tested, so as to perform information data processing on the target interface information. It can be understood that the target interface information may be one or more of the interface information to be tested, which is not limited in this embodiment of the present invention. Another understandable thing is that different target interface information may correspond to different information data processing.
S130、根据信息数据处理结果对所述待测试接口进行接口测试。S130. Perform an interface test on the interface to be tested according to the information data processing result.
其中,信息数据处理结果可以是信息数据处理得到的结果。Wherein, the information data processing result may be a result obtained by information data processing.
在本发明实施例中,在对目标接口信息进行信息数据处理之后,可以进一步根据信息数据处理结果对待测试接口进行接口测试。可选的,根据信息数据处理结果对待测试接口进行接口测试,可以根据信息数据处理结果确定待测试接口对应的接口测试用例,以通过接口测试用例对待测试接口进行接口请求,从而根据接口请求的反馈数据确定待测试接口的功能是否正常。In the embodiment of the present invention, after information data processing is performed on the target interface information, an interface test may be further performed on the interface to be tested according to the information data processing result. Optionally, the interface test is performed on the interface to be tested according to the information data processing result, and the interface test case corresponding to the interface to be tested can be determined according to the information data processing result, so that the interface request is made on the interface to be tested through the interface test case, so that according to the feedback of the interface request The data determine whether the function of the interface under test is normal.
本实施例的技术方案,通过获取待测试接口信息,并根据待测试接口信息确定待测试接口,以根据待测试接口信息确定待测试接口对应的目标接口信息,并对目标接口信息进行信息数据处理,从而根据信息数据处理结果对待测试接口进行接口测试,解决了现有技术中由于测试数据不全面和测试耗时长导致的测试场景覆盖率低和测试效率低的问题,能够提高接口测试的测试效率以及测试场景的覆盖率,从而提高了接口的有效性和稳定性。In the technical solution of this embodiment, by obtaining the information of the interface to be tested, and determining the interface to be tested according to the information of the interface to be tested, the information of the target interface corresponding to the interface to be tested is determined according to the information of the interface to be tested, and information data processing is performed on the information of the target interface , so that the interface test is performed on the interface to be tested according to the information data processing results, which solves the problems of low test scenario coverage and low test efficiency in the prior art due to incomplete test data and long test time, and can improve the test efficiency of the interface test As well as the coverage of test scenarios, thereby improving the effectiveness and stability of the interface.
实施例二Embodiment two
图2是本发明实施例二提供的一种接口测试方法的流程图,本实施例是对上述各技术方案的进一步细化,给出了获取待测试接口信息,对所述目标接口信息进行信息数据处理,以及根据信息数据处理结果对所述待测试接口进行接口测试的多种具体可选的实现方式。本实施例中的技术方案可以与上述一个或多个实施例中的各个可选方案结合。如图2所示,该方法可以包括如下步骤:Fig. 2 is a flow chart of an interface testing method provided by Embodiment 2 of the present invention. This embodiment is a further refinement of the above-mentioned technical solutions. Data processing, and various specific optional implementation modes of performing interface testing on the interface to be tested according to the information and data processing results. The technical solutions in this embodiment may be combined with the optional solutions in one or more of the foregoing embodiments. As shown in Figure 2, the method may include the following steps:
S210、确定待存储接口,并获取待存储接口对应的待存储接口信息。S210. Determine the interface to be stored, and acquire the information of the interface to be stored corresponding to the interface to be stored.
S220、按照预设规则将待存储接口信息存储在接口信息文档中。S220. Store the interface information to be stored in the interface information file according to a preset rule.
其中,待存储接口可以是等待存储接口信息的任意接口,例如可以是未存储过接口信息的接口,也可以是存储过接口信息但是需要对接口信息进行更新的接口,或者还可以是存储过接口信息但是还需要新增接口信息的接口等,本发明实施例对此并不进行限制。待存储接口信息可以的待存储接口对应的任意接口信息,例如可以是新增的接口信息,也可以是更新的接口信息等,本发明实施例对此并不进行限制。预设规则可以是预先设定的存储接口信息的规则,例如可以是预先设定的存储接口信息的数据类型规则,也可以是预先设定的存储接口信息的先后顺序规则等,本发明实施例对此并不进行限制。接口信息文档可以是用于存储待存储接口信息的文档,例如可以是txt文档,也可以是excel文档等,本发明实施例对此并不进行限制。Wherein, the interface to be stored may be any interface waiting to store interface information, for example, it may be an interface that has not stored interface information, or an interface that has stored interface information but needs to update the interface information, or may also be an interface that has been stored However, it is necessary to add an interface of interface information, etc., which is not limited in this embodiment of the present invention. The interface information to be stored may be any interface information corresponding to the interface to be stored, for example, it may be newly added interface information or updated interface information, which is not limited in this embodiment of the present invention. The preset rule may be a preset rule for storing interface information, for example, it may be a preset data type rule for storing interface information, or a preset order rule for storing interface information. The embodiment of the present invention There is no limit to this. The interface information document may be a document for storing the interface information to be stored, for example, it may be a txt document, or an excel document, etc., which is not limited in this embodiment of the present invention.
在本发明实施例中,确定待存储接口,以获取待存储接口对应的待存储接口信息,以按照预设规则将待存储接口信息存储在接口信息文档中。可以理解的是,在软件系统开发完成后,可以将软件系统中的任意接口确定为待存储接口,以将待存储接口的待存储接口信息存储在接口信息文档中。In the embodiment of the present invention, the interface to be stored is determined to obtain the interface information to be stored corresponding to the interface to be stored, so as to store the interface information to be stored in the interface information file according to a preset rule. It can be understood that after the development of the software system is completed, any interface in the software system can be determined as an interface to be stored, so as to store the interface information of the interface to be stored in the interface information file.
S230、获取接口信息文档中的待测试接口信息,并根据所述待测试接口信息确定待测试接口。S230. Acquire the information of the interface to be tested in the interface information file, and determine the interface to be tested according to the information of the interface to be tested.
在本发明实施例中,在按照预设规则将待存储接口信息存储在接口信息文档之后,可以进一步获取接口信息文档中的待测试接口信息,以根据待测试接口信息确定待测试接口。In the embodiment of the present invention, after the interface information to be stored is stored in the interface information file according to preset rules, the interface information to be tested in the interface information file can be further obtained to determine the interface to be tested according to the interface information to be tested.
S240、根据所述待测试接口信息确定所述待测试接口对应的待修改接口信息,并对所述待修改接口信息进行接口信息修改。S240. Determine the interface information to be modified corresponding to the interface to be tested according to the interface information to be tested, and modify the interface information on the interface information to be modified.
其中,待修改接口信息可以是等待修改的待测试接口的任意接口信息,例如可以是接口请求方法信息,也可以是正则提取信息,或者还可以是请求数据信息等,本发明实施例对此并不进行限制。接口信息修改可以是对待修改接口信息进行修改。Wherein, the interface information to be modified can be any interface information of the interface to be tested waiting to be modified, for example, it can be interface request method information, regular extraction information, or request data information, etc. This embodiment of the present invention does not include No restrictions are imposed. The interface information modification may be to modify the interface information to be modified.
在本发明实施例中,在根据待测试接口信息确定待测试接口之后,可以进一步根据待测试接口信息确定待测试接口对应的待修改接口信息,以对待修改接口信息进行接口信息修改。可以理解的是,可以根据测试需求对待修改接口信息进行接口信息修改,也可以根据接口信息类型对待修改接口信息进行接口信息修改等,本发明实施例对此并不进行限制。In the embodiment of the present invention, after the interface to be tested is determined according to the interface to be tested information, the interface information to be modified corresponding to the interface to be tested may be further determined according to the interface to be tested information, so as to modify the interface information of the interface information to be modified. It can be understood that the interface information to be modified can be modified according to the test requirements, or the interface information can be modified according to the type of the interface information, which is not limited in this embodiment of the present invention.
S250、根据所述待测试接口信息确定所述待测试接口对应的待替换请求参数,并对所述待替换请求参数进行参数数据替换。S250. Determine, according to the information about the interface to be tested, a request parameter to be replaced corresponding to the interface to be tested, and perform parameter data replacement on the request parameter to be replaced.
其中,待替换请求参数可以是等待替换的待测试接口的任意请求参数。示例性的,假设待测试接口为登录接口,则待替换请求参数可以是用户名或密码等。参数数据替换可以是对待替换请求参数的参数数据进行替换。Wherein, the request parameter to be replaced may be any request parameter of the interface to be tested waiting to be replaced. Exemplarily, assuming that the interface to be tested is a login interface, the request parameter to be replaced may be a user name or a password. The parameter data replacement may be to replace the parameter data of the request parameter to be replaced.
在本发明实施例中,在根据待测试接口信息确定待测试接口之后,可以进一步根据待测试接口信息确定待测试接口对应的待替换请求参数,以对待替换请求参数进行参数数据替换。In the embodiment of the present invention, after the interface to be tested is determined according to the information of the interface to be tested, the request parameter to be replaced corresponding to the interface to be tested may be further determined according to the information of the interface to be tested, so as to perform parameter data replacement for the request parameter to be replaced.
可选的,对待替换请求参数进行参数数据替换,可以包括:确定待替换请求参数对应的待替换请求参数值,以及待替换请求参数对应的请求参数变量;将待替换请求参数值替换为请求参数变量,并确定请求参数变量对应的变量取值集合;根据变量取值集合对请求参数变量进行变量取值替换。Optionally, replacing the parameter data of the request parameter to be replaced may include: determining the request parameter value to be replaced corresponding to the request parameter to be replaced, and the request parameter variable corresponding to the request parameter to be replaced; replacing the request parameter value to be replaced with the request parameter variable, and determine the variable value set corresponding to the request parameter variable; perform variable value replacement on the request parameter variable according to the variable value set.
其中,待替换请求参数值可以是待替换请求参数对应的参数取值。示例性的,假设待替换请求参数为用户名,则待替换请求参数值可以是用户在注册时所用的名称。请求参数变量可以是待替换请求参数对应的变量。示例性的,待替换请求参数用户名对应的请求参数变量可以是变量a,待替换请求参数密码对应的请求参数变量可以是变量b。变量取值集合可以是请求参数变量对应的取值所构成的集合。示例性的,假设待替换请求参数用户名对应的请求参数变量是变量a,则变量a的变量取值集合可以是{用户名1、用户名2、用户名3}。变量取值替换可以是对请求参数变量的取值进行替换。Wherein, the value of the request parameter to be replaced may be a parameter value corresponding to the request parameter to be replaced. Exemplarily, assuming that the request parameter to be replaced is a user name, the value of the request parameter to be replaced may be the name used by the user when registering. The request parameter variable may be a variable corresponding to the request parameter to be replaced. Exemplarily, the request parameter variable corresponding to the username of the request parameter to be replaced may be variable a, and the request parameter variable corresponding to the password of the request parameter to be replaced may be variable b. The variable value set may be a set of values corresponding to request parameter variables. Exemplarily, assuming that the request parameter variable corresponding to the request parameter username to be replaced is variable a, the variable value set of variable a may be {username 1, username 2, username 3}. The variable value replacement may be to replace the value of the request parameter variable.
具体的,在根据待测试接口信息确定待测试接口对应的待替换请求参数之后,可以进一步确定待替换请求参数对应的待替换请求参数值和待替换请求参数对应的请求参数变量,以将待替换请求参数值替换为请求参数变量,再确定请求参数变量对应的变量取值集合,从而根据变量取值集合对请求参数变量进行变量取值替换。Specifically, after the request parameter to be replaced corresponding to the interface to be tested is determined according to the interface to be tested, the request parameter value to be replaced corresponding to the request parameter to be replaced and the request parameter variable corresponding to the request parameter to be replaced may be further determined, so as to replace The request parameter value is replaced with the request parameter variable, and then the variable value set corresponding to the request parameter variable is determined, so as to perform variable value replacement on the request parameter variable according to the variable value set.
示例性的,假设待替换请求参数为用户名,待替换请求参数值为用户名A,也即“用户名为用户名A”,请求参数变量为变量a,则将待替换请求参数值替换为请求参数变量,可以得到“用户名为变量a”,再确定变量a的变量取值集合{你,我,他},则根据变量取值结合对请求参数变量进行变量取值替换,可以得到“用户名为你”,“用户名为我”,“用户名为他”。Exemplarily, assuming that the request parameter to be replaced is a username, the value of the request parameter to be replaced is username A, that is, "the username is username A", and the request parameter variable is variable a, then the value of the request parameter to be replaced is replaced by Request parameter variable, you can get "user name variable a", and then determine the variable value set {you, me, him} of variable a, then perform variable value replacement on the request parameter variable according to the combination of variable values, you can get " User name is you", "User name is me", "User name is him".
可选的,根据变量取值集合对请求参数变量进行变量取值替换,可以包括:获取算法选择指令,并根据算法选择指令确定取值替换算法;其中,取值替换算法为正交试验算法或笛卡尔积算法;根据取值替换算法和变量取值集合,对请求参数变量进行变量取值替换。Optionally, performing variable value replacement on the request parameter variable according to the variable value set may include: obtaining an algorithm selection instruction, and determining a value replacement algorithm according to the algorithm selection instruction; wherein, the value replacement algorithm is an orthogonal test algorithm or Cartesian product algorithm; according to the value replacement algorithm and the variable value set, variable value replacement is performed on the request parameter variable.
其中,算法选择指令可以是选择取值替换算法的指令。可以理解的是,算法选择指令可以是用户根据测试需求确定的。取值替换算法可以是对请求参数变量的取值进行替换的算法,例如可以是正交试验算法或笛卡尔积算法等,本发明实施例对此并不进行限制。Wherein, the algorithm selection instruction may be an instruction for selecting a value replacement algorithm. It can be understood that the algorithm selection instruction may be determined by the user according to the testing requirements. The value replacement algorithm may be an algorithm for replacing the value of the request parameter variable, for example, it may be an orthogonal test algorithm or a Cartesian product algorithm, which is not limited in this embodiment of the present invention.
具体的,在确定请求参数变量对应的变量取值集合之后,可以进一步获取算法选择指令,以根据算法选择指令确定取值替换算法,以根据取值替换算法和变量取值集合对请求参数变量进行变量取值替换。Specifically, after determining the variable value set corresponding to the request parameter variable, the algorithm selection instruction can be further obtained to determine the value replacement algorithm according to the algorithm selection instruction, so as to perform the request parameter variable according to the value replacement algorithm and the variable value set Variable value substitution.
示例性的,假设待替换请求参数包括参数1和参数2,参数1对应的请求参数变量为变量1,参数2对应的请求参数变量为变量2,且变量1的变量取值集合为{a,b},变量2的变量取值集合为{c,d},则根据取值替换算法和变量取值集合对请求参数变量进行变量取值替换,可以得到变量取值替换结果:“参数1为a且参数2为c”,“参数1为a且参数2为d”,“参数1为b且参数2为c”,“参数1为b且参数2为d”。For example, assume that the request parameters to be replaced include parameter 1 and parameter 2, the request parameter variable corresponding to parameter 1 is variable 1, the request parameter variable corresponding to parameter 2 is variable 2, and the variable value set of variable 1 is {a, b}, the variable value set of variable 2 is {c, d}, then perform variable value replacement on the request parameter variable according to the value replacement algorithm and variable value set, and the variable value replacement result can be obtained: "parameter 1 is a and parameter 2 is c", "parameter 1 is a and parameter 2 is d", "parameter 1 is b and parameter 2 is c", "parameter 1 is b and parameter 2 is d".
需要说明的是,本发明实施例并不对S240和S250的顺序进行限定,也即,S240和S250可以同步进行。It should be noted that, the embodiment of the present invention does not limit the sequence of S240 and S250, that is, S240 and S250 may be performed synchronously.
S260、根据信息数据处理结果对所述待测试接口进行接口测试。S260. Perform an interface test on the interface to be tested according to the information data processing result.
可选的,该方法还可以包括:获取环境选择指令,并根据环境选择指令确定目标测试环境;根据目标测试环境确定待测试接口对应的请求地址;相应的,根据信息数据处理结果对待测试接口进行接口测试,可以包括:根据信息数据处理结果和请求地址,对待测试接口进行接口测试。Optionally, the method may further include: obtaining an environment selection instruction, and determining the target test environment according to the environment selection instruction; determining the request address corresponding to the interface to be tested according to the target test environment; The interface test may include: performing an interface test on the interface to be tested according to the information data processing result and the request address.
其中,环境选择指令可以是选择测试环境的指令。可以理解的是,环境选择指令可以是用户根据测试需求确定的。测试环境可以是软件系统上线前对软件系统中的接口进行测试的环境,也可以是软件系统上线后也即软件系统应用过程中对软件系统中的接口进行测试的环境。目标测试环境可以是多个测试环境中的目标环境。可以理解的是,测试环境不同,可以对应不同的请求地址。Wherein, the environment selection instruction may be an instruction for selecting a test environment. It can be understood that the environment selection instruction may be determined by the user according to the test requirements. The testing environment may be an environment in which interfaces in the software system are tested before the software system goes online, or an environment in which interfaces in the software system are tested after the software system goes online, that is, during the application process of the software system. A target test environment may be a target environment in a plurality of test environments. It is understandable that different test environments may correspond to different request addresses.
具体的,获取环境选择指令,以根据环境选择指令确定目标测试环境,从而根据目标测试环境确定待测试接口对应的请求地址,进而根据信息数据处理结果和请求地址对待测试接口进行接口测试。Specifically, the environment selection instruction is obtained to determine the target test environment according to the environment selection instruction, thereby determining the request address corresponding to the interface to be tested according to the target test environment, and then performing interface testing on the interface to be tested according to the information data processing result and the request address.
可选的,在目标接口信息包括待修改接口信息时,根据信息数据处理结果对待测试接口进行接口测试,可以包括:根据接口信息修改结果对待测试接口进行接口单一测试。Optionally, when the target interface information includes the interface information to be modified, performing an interface test on the interface to be tested according to the information data processing result may include: performing a single interface test on the interface to be tested according to the modification result of the interface information.
其中,接口信息修改结果可以是对待修改接口信息进行修改得到的结果。接口单一测试可以是对待测试接口进行单一测试。具体的,在目标接口信息包括待修改接口信息时,在对待修改接口信息进行接口信息修改之后,可以进一步根据接口信息修改结果对待测试接口进行接口单一测试。Wherein, the interface information modification result may be a result obtained by modifying the interface information to be modified. A single test of an interface may be a single test of the interface to be tested. Specifically, when the target interface information includes the interface information to be modified, after the interface information is modified on the interface information to be modified, an interface single test may be further performed on the interface to be tested according to the modification result of the interface information.
可选的,在目标接口信息包括待替换请求参数时,根据信息数据处理结果对待测试接口进行接口测试,可以包括:根据参数数据替换结果对待测试接口进行接口批量测试。Optionally, when the target interface information includes request parameters to be replaced, performing an interface test on the to-be-tested interface according to the information data processing result may include: performing interface batch testing on the to-be-tested interface according to the parameter data replacement result.
其中,参数数据替换结果可以是对待替换请求参数的参数数据进行替换得到的结果。接口批量测试可以是对待测试接口进行批量测试。具体的,在目标接口信息包括待替换请求参数时,在对待替换请求参数进行参数数据替换之后,可以进一步根据参数数据替换结果对待测试接口进行接口批量测试。Wherein, the parameter data replacement result may be a result obtained by replacing the parameter data of the request parameter to be replaced. The interface batch test may be to perform batch testing on the interfaces to be tested. Specifically, when the target interface information includes the request parameters to be replaced, after the parameter data replacement is performed on the request parameters to be replaced, the interface batch test may be further performed on the interfaces to be tested according to the result of the parameter data replacement.
可选的,根据参数数据替换结果对待测试接口进行接口批量测试,可以根据参数数据替换结果生成待测试接口对应的至少两个接口测试用例,以根据各接口测试用例对待测试接口进行接口批量测试。Optionally, perform interface batch testing on the interface to be tested according to the parameter data replacement result, at least two interface test cases corresponding to the interface to be tested may be generated according to the parameter data replacement result, so as to perform interface batch testing on the interface to be tested according to each interface test case.
在本发明实施例的一个具体示例中,图3是本发明实施例二提供的一种接口测试方法的示例流程图,如图3所示,该方法具体可以包括:(1)获取接口信息文档(如excel格式的文档),并读取接口信息文档中的待测试接口信息(如名称、URL、方式、参数、返回参数等),确定待测试接口。(2)选择测试环境,也即根据环境选择指令确定目标测试环境。(3)对待测试接口进行单一测试,或者批量生成请求参数,也即参数数据替换结果对待测试接口进行批量测试。(4)保存测试用例。In a specific example of the embodiment of the present invention, Fig. 3 is an exemplary flow chart of an interface testing method provided in Embodiment 2 of the present invention, as shown in Fig. 3 , the method may specifically include: (1) obtaining an interface information document (such as a document in excel format), and read the interface information to be tested (such as name, URL, method, parameter, return parameter, etc.) in the interface information document to determine the interface to be tested. (2) Select the test environment, that is, determine the target test environment according to the environment selection instruction. (3) Perform a single test on the interface to be tested, or generate request parameters in batches, that is, perform batch testing on the interfaces to be tested as a result of parameter data replacement. (4) Save the test case.
示例性的,图4是本发明实施例二提供的一种接口测试界面的示意图,在确定接口信息文档之后,可以获取接口信息文档中的待测试接口信息,如图4中的接口名称、用例标题、URL、请求方法、正则提取、断言、请求参数(也即Body),可以将图4中的接口名称、用例标题、请求方法、正则提取、断言、请求参数确定为待修改接口信息,在对待修改接口信息进行接口信息修改之后,可以通过“单个调试”按钮对待测试接口进行接口单一测试。Exemplarily, FIG. 4 is a schematic diagram of an interface test interface provided by Embodiment 2 of the present invention. After the interface information document is determined, the interface information to be tested in the interface information document can be obtained, such as interface name and use case in FIG. 4 Title, URL, request method, regular extraction, assertion, request parameters (that is, Body), the interface name, use case title, request method, regular extraction, assertion, and request parameters in Figure 4 can be determined as the interface information to be modified. After modifying the interface information of the interface to be modified, the single interface test can be performed on the interface to be tested through the "Single Debug" button.
示例性的,图5是本发明实施例二提供的另一种接口测试界面的示意图,如图5所示,可以将变量取值集合放在“模板”位置处,可以将“将待替换请求参数值替换为请求参数变量”的替换结果放在请求参数(也即Body)位置处,选择取值替换算法(正交试验或笛卡尔积算法),也即根据算法选择指令确定取值替换算法,点击“获取数据”按钮即可根据所述取值替换算法和所述变量取值集合,对所述请求参数变量进行变量取值替换。Exemplarily, FIG. 5 is a schematic diagram of another interface test interface provided by Embodiment 2 of the present invention. As shown in FIG. 5, the variable value set can be placed in the "template" position, and the "request to be replaced Replace the parameter value with the request parameter variable" and put the replacement result at the position of the request parameter (that is, Body), and select the value replacement algorithm (orthogonal test or Cartesian product algorithm), that is, determine the value replacement algorithm according to the algorithm selection instruction , click the "Get Data" button to perform variable value replacement on the request parameter variable according to the value replacement algorithm and the variable value set.
本实施例的技术方案,通过确定待存储接口,获取待存储接口对应的待存储接口信息,按照预设规则将待存储接口信息存储在接口信息文档中,以获取接口信息文档中的待测试接口信息,并根据待测试接口信息确定待测试接口,以根据待测试接口信息确定待测试接口对应的待修改接口信息,对待修改接口信息进行接口信息修改,以根据待测试接口信息确定待测试接口对应的待替换请求参数,对待替换请求参数进行参数数据替换,从而根据接口信息修改结果或参数数据替换结果对待测试接口进行接口测试,解决了现有技术中由于测试数据不全面和测试耗时长导致的测试场景覆盖率低和测试效率低的问题,能够提高接口测试的测试效率以及测试场景的覆盖率,从而提高了接口的有效性和稳定性。In the technical solution of this embodiment, by determining the interface to be stored, the interface information to be stored corresponding to the interface to be stored is obtained, and the interface information to be stored is stored in the interface information file according to preset rules, so as to obtain the interface to be tested in the interface information file Information, and determine the interface to be tested according to the information of the interface to be tested, so as to determine the interface information to be modified corresponding to the interface to be tested according to the information of the interface to be tested, modify the interface information on the interface information to be modified, so as to determine the corresponding The request parameters to be replaced, the parameter data replacement is performed on the request parameters to be replaced, and the interface test is performed on the interface to be tested according to the interface information modification result or the parameter data replacement result, which solves the problems caused by incomplete test data and long test time in the prior art The problem of low test scenario coverage and low test efficiency can improve the test efficiency of interface testing and the coverage of test scenarios, thereby improving the effectiveness and stability of the interface.
实施例三Embodiment Three
图6是本发明实施例三提供的一种接口测试装置的示意图,如图6所示,所述装置包括:待测试接口确定模块610、信息数据处理模块620以及接口测试模块630,其中:FIG. 6 is a schematic diagram of an interface testing device provided in Embodiment 3 of the present invention. As shown in FIG. 6, the device includes: an
待测试接口确定模块610,用于获取待测试接口信息,并根据所述待测试接口信息确定待测试接口;The interface to be tested determining
信息数据处理模块620,用于根据所述待测试接口信息确定所述待测试接口对应的目标接口信息,并对所述目标接口信息进行信息数据处理;An information
接口测试模块630,用于根据信息数据处理结果对所述待测试接口进行接口测试。The
本实施例的技术方案,通过获取待测试接口信息,并根据待测试接口信息确定待测试接口,以根据待测试接口信息确定待测试接口对应的目标接口信息,并对目标接口信息进行信息数据处理,从而根据信息数据处理结果对待测试接口进行接口测试,解决了现有技术中由于测试数据不全面和测试耗时长导致的测试场景覆盖率低和测试效率低的问题,能够提高接口测试的测试效率以及测试场景的覆盖率,从而提高了接口的有效性和稳定性。In the technical solution of this embodiment, by obtaining the information of the interface to be tested, and determining the interface to be tested according to the information of the interface to be tested, the information of the target interface corresponding to the interface to be tested is determined according to the information of the interface to be tested, and information data processing is performed on the information of the target interface , so that the interface test is performed on the interface to be tested according to the information data processing results, which solves the problems of low test scenario coverage and low test efficiency in the prior art due to incomplete test data and long test time, and can improve the test efficiency of the interface test As well as the coverage of test scenarios, thereby improving the effectiveness and stability of the interface.
可选的,所述装置,还可以具体用于:获取环境选择指令,并根据环境选择指令确定目标测试环境;根据目标测试环境确定待测试接口对应的请求地址;相应的,接口测试模块630,可以具体用于:根据信息数据处理结果和请求地址,对待测试接口进行接口测试。Optionally, the device may also be specifically used to: obtain an environment selection instruction, and determine the target test environment according to the environment selection instruction; determine the request address corresponding to the interface to be tested according to the target test environment; correspondingly, the
可选的,待测试接口确定模块610,可以具体用于:确定待存储接口,并获取待存储接口对应的待存储接口信息;按照预设规则将待存储接口信息存储在接口信息文档中;获取接口信息文档中的待测试接口信息。Optionally, the interface to be tested determining
可选的,目标接口信息可以包括待修改接口信息;相应的,信息数据处理模块620,可以具体用于:对待修改接口信息进行接口信息修改;相应的,接口测试模块630,可以具体用于:根据接口信息修改结果对待测试接口进行接口单一测试。Optionally, the target interface information may include the interface information to be modified; correspondingly, the information
可选的,目标接口信息可以包括待替换请求参数;相应的,信息数据处理模块620,可以具体用于:对待替换请求参数进行参数数据替换;相应的,接口测试模块630,可以具体用于:根据参数数据替换结果对待测试接口进行接口批量测试。Optionally, the target interface information may include request parameters to be replaced; correspondingly, the information
可选的,信息数据处理模块620,可以进一步用于:确定待替换请求参数对应的待替换请求参数值,以及待替换请求参数对应的请求参数变量;将待替换请求参数值替换为请求参数变量,并确定请求参数变量对应的变量取值集合;根据变量取值集合对请求参数变量进行变量取值替换。Optionally, the information
可选的,信息数据处理模块620,还可以进一步用于:获取算法选择指令,并根据算法选择指令确定取值替换算法;其中,取值替换算法为正交试验算法或笛卡尔积算法;根据取值替换算法和变量取值集合,对请求参数变量进行变量取值替换。Optionally, the information
本发明实施例所提供的接口测试装置可执行本发明任意实施例所提供的接口测试方法,具备执行方法相应的功能模块和有益效果。The interface testing device provided in the embodiment of the present invention can execute the interface testing method provided in any embodiment of the present invention, and has corresponding functional modules and beneficial effects for executing the method.
实施例四Embodiment four
图7示出了可以用来实施本发明的实施例的电子设备10的结构示意图。电子设备旨在表示各种形式的数字计算机,诸如,膝上型计算机、台式计算机、工作台、个人数字助理、服务器、刀片式服务器、大型计算机、和其它适合的计算机。电子设备还可以表示各种形式的移动装置,诸如,个人数字处理、蜂窝电话、智能电话、可穿戴设备(如头盔、眼镜、手表等)和其它类似的计算装置。本文所示的部件、它们的连接和关系、以及它们的功能仅仅作为示例,并且不意在限制本文中描述的和/或者要求的本发明的实现。FIG. 7 shows a schematic structural diagram of an
如图7所示,电子设备10包括至少一个处理器11,以及与至少一个处理器11通信连接的存储器,如只读存储器(ROM)12、随机访问存储器(RAM)13等,其中,存储器存储有可被至少一个处理器执行的计算机程序,处理器11可以根据存储在只读存储器(ROM)12中的计算机程序或者从存储单元18加载到随机访问存储器(RAM)13中的计算机程序,来执行各种适当的动作和处理。在RAM 13中,还可存储电子设备10操作所需的各种程序和数据。处理器11、ROM 12以及RAM 13通过总线14彼此相连。输入/输出(I/O)接口15也连接至总线14。As shown in FIG. 7 , the
电子设备10中的多个部件连接至I/O接口15,包括:输入单元16,例如键盘、鼠标等;输出单元17,例如各种类型的显示器、扬声器等;存储单元18,例如磁盘、光盘等;以及通信单元19,例如网卡、调制解调器、无线通信收发机等。通信单元19允许电子设备10通过诸如因特网的计算机网络和/或各种电信网络与其他设备交换信息/数据。Multiple components in the
处理器11可以是各种具有处理和计算能力的通用和/或专用处理组件。处理器11的一些示例包括但不限于中央处理单元(CPU)、图形处理单元(GPU)、各种专用的人工智能(AI)计算芯片、各种运行机器学习模型算法的处理器、数字信号处理器(DSP)、以及任何适当的处理器、控制器、微控制器等。处理器11执行上文所描述的各个方法和处理,例如接口测试方法。
在一些实施例中,接口测试方法可被实现为计算机程序,其被有形地包含于计算机可读存储介质,例如存储单元18。在一些实施例中,计算机程序的部分或者全部可以经由ROM 12和/或通信单元19而被载入和/或安装到电子设备10上。当计算机程序加载到RAM 13并由处理器11执行时,可以执行上文描述的接口测试方法的一个或多个步骤。备选地,在其他实施例中,处理器11可以通过其他任何适当的方式(例如,借助于固件)而被配置为执行接口测试方法。In some embodiments, the interface testing method can be implemented as a computer program, which is tangibly embodied in a computer-readable storage medium, such as the
本文中以上描述的系统和技术的各种实施方式可以在数字电子电路系统、集成电路系统、场可编程门阵列(FPGA)、专用集成电路(ASIC)、专用标准产品(ASSP)、芯片上系统的系统(SOC)、负载可编程逻辑设备(CPLD)、计算机硬件、固件、软件、和/或它们的组合中实现。这些各种实施方式可以包括:实施在一个或者多个计算机程序中,该一个或者多个计算机程序可在包括至少一个可编程处理器的可编程系统上执行和/或解释,该可编程处理器可以是专用或者通用可编程处理器,可以从存储系统、至少一个输入装置、和至少一个输出装置接收数据和指令,并且将数据和指令传输至该存储系统、该至少一个输入装置、和该至少一个输出装置。Various implementations of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application specific integrated circuits (ASICs), application specific standard products (ASSPs), systems on chips Implemented in a system of systems (SOC), load programmable logic device (CPLD), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include being implemented in one or more computer programs executable and/or interpreted on a programmable system including at least one programmable processor, the programmable processor Can be special-purpose or general-purpose programmable processor, can receive data and instruction from storage system, at least one input device, and at least one output device, and transmit data and instruction to this storage system, this at least one input device, and this at least one output device an output device.
用于实施本发明的方法的计算机程序可以采用一个或多个编程语言的任何组合来编写。这些计算机程序可以提供给通用计算机、专用计算机或其他可编程数据处理装置的处理器,使得计算机程序当由处理器执行时使流程图和/或框图中所规定的功能/操作被实施。计算机程序可以完全在机器上执行、部分地在机器上执行,作为独立软件包部分地在机器上执行且部分地在远程机器上执行或完全在远程机器或服务器上执行。Computer programs for implementing the methods of the present invention may be written in any combination of one or more programming languages. These computer programs can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing apparatus, so that the computer program causes the functions/operations specified in the flowcharts and/or block diagrams to be implemented when executed by the processor. A computer program may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
在本发明的上下文中,计算机可读存储介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的计算机程序。计算机可读存储介质可以包括但不限于电子的、磁性的、光学的、电磁的、红外的、或半导体系统、装置或设备,或者上述内容的任何合适组合。备选地,计算机可读存储介质可以是机器可读信号介质。机器可读存储介质的更具体示例会包括基于一个或多个线的电气连接、便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或快闪存储器)、光纤、便捷式紧凑盘只读存储器(CD-ROM)、光学储存设备、磁储存设备、或上述内容的任何合适组合。In the context of the present invention, a computer readable storage medium may be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus or device. A computer readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, a computer readable storage medium may be a machine readable signal medium. More specific examples of machine-readable storage media would include one or more wire-based electrical connections, portable computer discs, hard drives, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, compact disk read only memory (CD-ROM), optical storage, magnetic storage, or any suitable combination of the foregoing.
为了提供与用户的交互,可以在电子设备上实施此处描述的系统和技术,该电子设备具有:用于向用户显示信息的显示装置(例如,CRT(阴极射线管)或者LCD(液晶显示器)监视器);以及键盘和指向装置(例如,鼠标或者轨迹球),用户可以通过该键盘和该指向装置来将输入提供给电子设备。其它种类的装置还可以用于提供与用户的交互;例如,提供给用户的反馈可以是任何形式的传感反馈(例如,视觉反馈、听觉反馈、或者触觉反馈);并且可以用任何形式(包括声输入、语音输入或者、触觉输入)来接收来自用户的输入。In order to provide interaction with the user, the systems and techniques described herein can be implemented on an electronic device having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display)) for displaying information to the user. monitor); and a keyboard and pointing device (eg, a mouse or a trackball) through which the user can provide input to the electronic device. Other kinds of devices can also be used to provide interaction with the user; for example, the feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and can be in any form (including Acoustic input, speech input or, tactile input) to receive input from the user.
可以将此处描述的系统和技术实施在包括后台部件的计算系统(例如,作为数据服务器)、或者包括中间件部件的计算系统(例如,应用服务器)、或者包括前端部件的计算系统(例如,具有图形用户界面或者网络浏览器的用户计算机,用户可以通过该图形用户界面或者该网络浏览器来与此处描述的系统和技术的实施方式交互)、或者包括这种后台部件、中间件部件、或者前端部件的任何组合的计算系统中。可以通过任何形式或者介质的数字数据通信(例如,通信网络)来将系统的部件相互连接。通信网络的示例包括:局域网(LAN)、广域网(WAN)、区块链网络和互联网。The systems and techniques described herein can be implemented in a computing system that includes back-end components (e.g., as a data server), or a computing system that includes middleware components (e.g., an application server), or a computing system that includes front-end components (e.g., as a a user computer having a graphical user interface or web browser through which a user can interact with embodiments of the systems and techniques described herein), or including such backend components, middleware components, Or any combination of front-end components in a computing system. The components of the system can be interconnected by any form or medium of digital data communication, eg, a communication network. Examples of communication networks include: local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.
计算系统可以包括客户端和服务器。客户端和服务器一般远离彼此并且通常通过通信网络进行交互。通过在相应的计算机上运行并且彼此具有客户端-服务器关系的计算机程序来产生客户端和服务器的关系。服务器可以是云服务器,又称为云计算服务器或云主机,是云计算服务体系中的一项主机产品,以解决了传统物理主机与VPS服务中,存在的管理难度大,业务扩展性弱的缺陷。A computing system can include clients and servers. Clients and servers are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also known as a cloud computing server or a cloud host. It is a host product in the cloud computing service system to solve the problems of difficult management and weak business expansion in traditional physical hosts and VPS services. defect.
应该理解,可以使用上面所示的各种形式的流程,重新排序、增加或删除步骤。例如,本发明中记载的各步骤可以并行地执行也可以顺序地执行也可以不同的次序执行,只要能够实现本发明的技术方案所期望的结果,本文在此不进行限制。It should be understood that steps may be reordered, added or deleted using the various forms of flow shown above. For example, each step described in the present invention may be executed in parallel, sequentially, or in a different order, as long as the desired result of the technical solution of the present invention can be achieved, there is no limitation herein.
上述具体实施方式,并不构成对本发明保护范围的限制。本领域技术人员应该明白的是,根据设计要求和其他因素,可以进行各种修改、组合、子组合和替代。任何在本发明的精神和原则之内所作的修改、等同替换和改进等,均应包含在本发明保护范围之内。The above specific implementation methods do not constitute a limitation to the protection scope of the present invention. It should be apparent to those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made depending on design requirements and other factors. Any modifications, equivalent replacements and improvements made within the spirit and principles of the present invention shall be included within the protection scope of the present invention.
Claims (10)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310324598.9A CN116303071B (en) | 2023-03-29 | 2023-03-29 | Interface testing method, device, electronic equipment and storage medium |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN202310324598.9A CN116303071B (en) | 2023-03-29 | 2023-03-29 | Interface testing method, device, electronic equipment and storage medium |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN116303071A true CN116303071A (en) | 2023-06-23 |
| CN116303071B CN116303071B (en) | 2024-12-03 |
Family
ID=86788595
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN202310324598.9A Active CN116303071B (en) | 2023-03-29 | 2023-03-29 | Interface testing method, device, electronic equipment and storage medium |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN116303071B (en) |
Citations (11)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20150378875A1 (en) * | 2014-06-27 | 2015-12-31 | Hcl Technologies Ltd. | Generating an optimized test suite from models for use in a software testing environment |
| US20180089072A1 (en) * | 2016-09-23 | 2018-03-29 | International Business Machines Corporation | Automated testing of application program interface |
| CN108153670A (en) * | 2017-11-30 | 2018-06-12 | 北京奇艺世纪科技有限公司 | A kind of interface test method, device and electronic equipment |
| CN109446071A (en) * | 2018-09-26 | 2019-03-08 | 深圳壹账通智能科技有限公司 | Interface test method, interface test device, electronic equipment and storage medium |
| WO2020119434A1 (en) * | 2018-12-15 | 2020-06-18 | 深圳壹账通智能科技有限公司 | Method and apparatus for interface data processing, method and apparatus for automated testing, device, and medium |
| CN111475402A (en) * | 2020-03-17 | 2020-07-31 | 中国平安人寿保险股份有限公司 | Program function testing method and related device |
| CN113360416A (en) * | 2021-07-22 | 2021-09-07 | 中国工商银行股份有限公司 | Test data batch generation method and device |
| CN113760697A (en) * | 2020-07-15 | 2021-12-07 | 北京沃东天骏信息技术有限公司 | Interface testing method and device, electronic equipment and storage medium |
| CN114077540A (en) * | 2020-08-21 | 2022-02-22 | 北京金山云网络技术有限公司 | Interface test system and interface test method |
| CN114185765A (en) * | 2021-09-29 | 2022-03-15 | 五八同城信息技术有限公司 | Test data processing method, device, electronic device and storage medium |
| CN115481026A (en) * | 2022-09-20 | 2022-12-16 | 上海浦东发展银行股份有限公司 | Test case generation method, device, computer equipment, storage medium |
-
2023
- 2023-03-29 CN CN202310324598.9A patent/CN116303071B/en active Active
Patent Citations (11)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20150378875A1 (en) * | 2014-06-27 | 2015-12-31 | Hcl Technologies Ltd. | Generating an optimized test suite from models for use in a software testing environment |
| US20180089072A1 (en) * | 2016-09-23 | 2018-03-29 | International Business Machines Corporation | Automated testing of application program interface |
| CN108153670A (en) * | 2017-11-30 | 2018-06-12 | 北京奇艺世纪科技有限公司 | A kind of interface test method, device and electronic equipment |
| CN109446071A (en) * | 2018-09-26 | 2019-03-08 | 深圳壹账通智能科技有限公司 | Interface test method, interface test device, electronic equipment and storage medium |
| WO2020119434A1 (en) * | 2018-12-15 | 2020-06-18 | 深圳壹账通智能科技有限公司 | Method and apparatus for interface data processing, method and apparatus for automated testing, device, and medium |
| CN111475402A (en) * | 2020-03-17 | 2020-07-31 | 中国平安人寿保险股份有限公司 | Program function testing method and related device |
| CN113760697A (en) * | 2020-07-15 | 2021-12-07 | 北京沃东天骏信息技术有限公司 | Interface testing method and device, electronic equipment and storage medium |
| CN114077540A (en) * | 2020-08-21 | 2022-02-22 | 北京金山云网络技术有限公司 | Interface test system and interface test method |
| CN113360416A (en) * | 2021-07-22 | 2021-09-07 | 中国工商银行股份有限公司 | Test data batch generation method and device |
| CN114185765A (en) * | 2021-09-29 | 2022-03-15 | 五八同城信息技术有限公司 | Test data processing method, device, electronic device and storage medium |
| CN115481026A (en) * | 2022-09-20 | 2022-12-16 | 上海浦东发展银行股份有限公司 | Test case generation method, device, computer equipment, storage medium |
Also Published As
| Publication number | Publication date |
|---|---|
| CN116303071B (en) | 2024-12-03 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN113127357B (en) | Unit testing methods, devices, equipment, storage media and program products | |
| CN115168130B (en) | A chip testing method, apparatus, electronic device, and storage medium | |
| CN115454971A (en) | Data migration method, device, electronic device and storage medium | |
| CN114443493A (en) | Test case generation method and device, electronic equipment and storage medium | |
| CN113766487A (en) | Cloud mobile phone information acquisition method, device, device and medium | |
| CN115598505A (en) | A chip detection method, device, equipment and storage medium | |
| CN116301997A (en) | A controller upgrade method, device, equipment and medium | |
| CN115442252A (en) | A call chain construction method, device, electronic equipment and readable storage medium | |
| CN116594708A (en) | Method, device, equipment and medium for generating multi-model loading configuration file | |
| CN113656268B (en) | Performance test method and device for business service, electronic equipment and storage medium | |
| CN115309730A (en) | Data auditing method, device, electronic device and storage medium | |
| CN114330221A (en) | Score board implementation method, score board, electronic device and storage medium | |
| CN117709255B (en) | Test method, device, equipment and medium for indirect access register | |
| CN115757275B (en) | Asset information management method and device, electronic equipment and storage medium | |
| CN116954570A (en) | Method, device, equipment and storage medium for generating analog data | |
| CN116303071A (en) | An interface testing method, device, electronic equipment and storage medium | |
| CN116319454A (en) | Method, device, equipment and storage medium for detecting time consumption of application program network | |
| CN116301978A (en) | System upgrading method, device, equipment and storage medium | |
| CN118132351A (en) | Disk array performance test method, device, equipment and medium | |
| CN116541224A (en) | Performance test method, device, electronic equipment and readable storage medium | |
| CN116627432A (en) | Front-end application automatic deployment method, device, equipment and medium | |
| CN115061925A (en) | Performance testing method, device and storage medium for heterogeneous acceleration program | |
| CN118568006B (en) | Application interface awakening method, device, equipment, storage medium and program product | |
| CN119720887B (en) | A register configuration method, device, equipment and medium | |
| CN113836021B (en) | Test method, device, electronic equipment and medium |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant | ||
| CP03 | Change of name, title or address |
Address after: Room 214, building 5, 1418 Xinzha Road, Jing'an District, Shanghai 200040 Patentee after: SHANGHAI JUSHUITAN NETWORK TECHNOLOGY Co.,Ltd. Country or region after: China Patentee after: Shanghai Juhuotong Intelligent Technology Co., Ltd. Address before: Room 214, building 5, 1418 Xinzha Road, Jing'an District, Shanghai 200040 Patentee before: SHANGHAI JUSHUITAN NETWORK TECHNOLOGY Co.,Ltd. Country or region before: China Patentee before: Shanghai juhuotong e-commerce Co.,Ltd. |
|
| CP03 | Change of name, title or address |