CN110209576A - The calculation method and relevant device of test case coverage rate - Google Patents
The calculation method and relevant device of test case coverage rate Download PDFInfo
- Publication number
- CN110209576A CN110209576A CN201910421939.8A CN201910421939A CN110209576A CN 110209576 A CN110209576 A CN 110209576A CN 201910421939 A CN201910421939 A CN 201910421939A CN 110209576 A CN110209576 A CN 110209576A
- Authority
- CN
- China
- Prior art keywords
- test case
- program
- identifiers
- target
- subroutines
- 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.)
- Pending
Links
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
-
- 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/3684—Test management for test design, e.g. generating new test cases
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
本申请涉及测试技术领域中的测试管理,尤其涉及一种测试用例覆盖率的计算方法及相关设备,应用于管理设备,该方法包括:获取目标测试用例和目标测试用例关联的目标程序;获取目标测试用例的M个测试用例标识和目标程序的N个程序标识;将N个程序标识中的每个程序标识与M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果;基于匹配结果确定测试用例覆盖率。采用本申请实施例可用于简化软件设计中代码缺陷的检验方法。
The present application relates to test management in the field of test technology, and in particular to a method for calculating test case coverage and related equipment, which are applied to management equipment. The method includes: obtaining target test cases and target programs associated with target test cases; obtaining target test cases M test case identifiers of the test case and N program identifiers of the target program; keyword matching is performed between each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result ; Determine test case coverage based on matching results. The embodiment of the present application can be used to simplify the inspection method for code defects in software design.
Description
技术领域technical field
本申请涉及测试技术领域,尤其涉及一种测试用例覆盖率的计算方法及相关设备。The present application relates to the technical field of testing, in particular to a method for calculating the coverage of test cases and related equipment.
背景技术Background technique
覆盖率是度量测试完整性的一个手段,是测试有效性的一个度量。目前,在软件开发过程中,检测软件设计缺陷的常用方法是计算代码的覆盖率。其具体实现方式为:编译阶段在源代码中插入探针函数,通过测试运行编译后的源代码来快速定位哪些代码没有被运行,从而发现软件设计中的缺陷。然而,这种代码缺陷检验方法需要测试人员具有编程能力,步骤繁琐复杂。Coverage is a measure of test completeness and a measure of test effectiveness. Currently, in the process of software development, a common method for detecting software design defects is to calculate the coverage rate of the code. The specific implementation method is as follows: inserting probe functions into the source code during the compilation stage, and quickly locating which codes are not executed by testing and running the compiled source code, thereby discovering defects in the software design. However, this code defect inspection method requires testers to have programming ability, and the steps are cumbersome and complicated.
发明内容Contents of the invention
本申请实施例提供一种测试用例覆盖率的计算方法及相关设备,用于简化软件设计中代码缺陷的检验方法。Embodiments of the present application provide a test case coverage calculation method and related equipment, which are used to simplify the inspection method for code defects in software design.
第一方面,本申请实施例提供一种测试用例覆盖率的计算方法,应用于管理设备,所述方法包括:In the first aspect, an embodiment of the present application provides a method for calculating test case coverage, which is applied to a management device, and the method includes:
获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数;Obtain the target program associated with the target test case and the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, and the target program has N subroutines, each subroutine corresponds to a program identification, the M and the N are both integers greater than or equal to 1;
获取所述目标测试用例的M个测试用例标识和所述目标程序的N个程序标识;Obtain M test case identifiers of the target test case and N program identifiers of the target program;
将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果;performing keyword matching on each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result;
基于所述匹配结果确定测试用例覆盖率。Test case coverage is determined based on the matching results.
第二方面,本申请实施例提供一种测试用例覆盖率的计算装置,应用于管理设备,所述装置包括:In the second aspect, the embodiment of the present application provides a test case coverage calculation device, which is applied to a management device, and the device includes:
获取单元,用于获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数;获取所述目标测试用例的M个测试用例标识和所述目标程序的N个程序标识;The acquisition unit is used to acquire the target test case and the target program associated with the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, and the target program has N subroutines, Each subroutine corresponds to a program identification, and the M and the N are integers greater than or equal to 1; obtain M test case identifications of the target test case and N program identifications of the target program;
匹配单元,用于将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果;A matching unit, configured to perform keyword matching on each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result;
确定单元,用于基于所述匹配结果确定测试用例覆盖率。A determining unit, configured to determine test case coverage based on the matching result.
第三方面,本申请实施例提供一种电子设备,包括处理器、存储器、通信接口以及一个或多个程序,其中,上述一个或多个程序被存储在上述存储器中,并且被配置由上述处理器执行,上述程序包括用于执行本申请实施例第一方面所述的方法中的步骤的指令。In a third aspect, an embodiment of the present application provides an electronic device, including a processor, a memory, a communication interface, and one or more programs, wherein the one or more programs are stored in the memory and are configured to be processed by the above-mentioned The above program includes instructions for executing the steps in the method described in the first aspect of the embodiments of the present application.
第四方面,本申请实施例提供了一种计算机可读存储介质,其中,上述计算机可读存储介质用于存储计算机程序,其中,上述计算机程序被处理器执行,以实现如本申请实施例第一方面所述的方法中所描述的部分或全部步骤。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the above-mentioned computer-readable storage medium is used to store a computer program, wherein the above-mentioned computer program is executed by a processor to implement the first Part or all of the steps described in the method described in one aspect.
第五方面,本申请实施例提供了一种计算机程序产品,其中,上述计算机程序产品包括存储了计算机程序的非瞬时性计算机可读存储介质,上述计算机程序可操作来使计算机执行如本申请实施例第一方面所述的方法中所描述的部分或全部步骤。该计算机程序产品可以为一个软件安装包。In a fifth aspect, the embodiment of the present application provides a computer program product, wherein the computer program product includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to enable the computer to execute the program as implemented in the present application. For example, some or all of the steps described in the method described in the first aspect. The computer program product may be a software installation package.
可以看出,在本申请实施例中,管理设备先获取目标测试用例和目标测试用例关联的目标程序,目标测试用例的M个子测试用例对应M个测试用例标识和目标程序的N个子程序对应N个程序标识,然后将每个程序标识与每个测试用例标识进行关键字匹配,基于所述匹配结果确定测试用例覆盖率。在将每个程序标识与每个测试用例标识进行关键字匹配的过程中,不需要对目标程序插入探针函数和编译运行,直接匹配测试用例标识和程序标识就可以得到测试用例覆盖率,然后通过测试用例覆盖率可以判断目标程序的完整程度,从而简化软件设计中代码缺陷的检验方法。It can be seen that in the embodiment of the present application, the management device first obtains the target test case and the target program associated with the target test case, and the M sub-test cases of the target test case correspond to the M test case identifiers and the N subroutines of the target program correspond to N Then each program ID is matched with each test case ID, and the test case coverage is determined based on the matching result. In the process of keyword matching each program ID with each test case ID, there is no need to insert probe functions and compile and run the target program, and the test case coverage can be obtained by directly matching the test case ID and program ID, and then The completeness of the target program can be judged by the test case coverage, thus simplifying the inspection method of code defects in software design.
附图说明Description of drawings
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only These are some embodiments of the present application. Those skilled in the art can also obtain other drawings based on these drawings without creative work.
图1是本申请实施例提供的一种测试用例覆盖率的计算方法的流程示意图;Fig. 1 is a schematic flow chart of a calculation method of test case coverage provided by the embodiment of the present application;
图2是本申请实施例提供的另一种测试用例覆盖率的计算方法的流程示意图;Fig. 2 is a schematic flow chart of another calculation method of test case coverage provided by the embodiment of the present application;
图3是本申请实施例提供的一种管理设备的结构示意图;FIG. 3 is a schematic structural diagram of a management device provided by an embodiment of the present application;
图4是本申请实施例提供的一种测试用例覆盖率的计算装置的结构示意图。FIG. 4 is a schematic structural diagram of a test case coverage calculation device provided by an embodiment of the present application.
具体实施方式Detailed ways
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiment of the application will be clearly and completely described below in conjunction with the accompanying drawings in the embodiment of the application. Obviously, the described embodiment is only It is an embodiment of a part of the application, but not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by persons of ordinary skill in the art without creative efforts shall fall within the protection scope of this application.
以下分别进行详细说明。Each will be described in detail below.
本申请的说明书和权利要求书及所述附图中的术语“第一”、“第二”、“第三”和“第四”等是用于区别不同对象,而不是用于描述特定顺序。此外,术语“包括”和“具有”以及它们任何变形,意图在于覆盖不排他的包含。例如包含了一系列步骤或单元的过程、方法、系统、产品或设备没有限定于已列出的步骤或单元,而是可选地还包括没有列出的步骤或单元,或可选地还包括对于这些过程、方法、产品或设备固有的其它步骤或单元。The terms "first", "second", "third" and "fourth" in the specification and claims of the present application and the drawings are used to distinguish different objects, rather than to describe a specific order . Furthermore, the terms "include" and "have", as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units is not limited to the listed steps or units, but optionally also includes unlisted steps or units, or optionally further includes For other steps or units inherent in these processes, methods, products or apparatuses.
在本文中提及“实施例”意味着,结合实施例描述的特定特征、结构或特性可以包含在本申请的至少一个实施例中。在说明书中的各个位置出现该短语并不一定均是指相同的实施例,也不是与其它实施例互斥的独立的或备选的实施例。本领域技术人员显式地和隐式地理解的是,本文所描述的实施例可以与其它实施例相结合。Reference herein to an "embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the present application. The occurrences of this phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is understood explicitly and implicitly by those skilled in the art that the embodiments described herein can be combined with other embodiments.
管理设备、第一电子设备和第二电子设备可以包括各种具有无线通信功能的手持设备、车载设备、可穿戴设备、计算设备、服务设备或连接到无线调制解调器的其他处理设备,以及各种形式的用户设备(User Equipment,UE),移动台(Mobile Station,MS),终端设备(terminal device)等等。The management device, the first electronic device and the second electronic device may include various handheld devices with wireless communication functions, vehicle-mounted devices, wearable devices, computing devices, service devices or other processing devices connected to wireless modems, and various forms of A user equipment (User Equipment, UE), a mobile station (Mobile Station, MS), a terminal device (terminal device) and so on.
请参见图1,图1是本申请实施例提供的一种测试用例覆盖率的计算方法的流程示意图,应用于管理设备,该方法包括:Please refer to FIG. 1. FIG. 1 is a schematic flowchart of a method for calculating test case coverage provided by an embodiment of the present application, which is applied to management devices. The method includes:
步骤101:获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数。Step 101: Acquire the target test case and the target program associated with the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, and the target program has N sub-programs, each sub-test A program corresponds to a program identifier, and both the M and the N are integers greater than or equal to 1.
其中,目标测试用例(Test Case)是为某个特殊目标而编制的一组测试输入、执行条件以及预期结果,以便测试某个程序路径或核实是否满足某个特定需求。测试用例包括以下至少一种信息:软件或项目的名称、软件或项目的版本、功能模块名、测试用例的简单描述、测试用例的参考信息、本测试用例与其他测试用例间的依赖关系、本用例的前置条件、用例的编号(ID)、步骤号、操作步骤描述、测试数据描述、预期结果和实际结果、开发人员和测试人员、测试执行日期。Among them, the target test case (Test Case) is a set of test inputs, execution conditions and expected results compiled for a special target, so as to test a program path or verify whether a specific requirement is met. A test case includes at least one of the following information: the name of the software or project, the version of the software or project, the name of the function module, a brief description of the test case, reference information of the test case, dependencies between this test case and other test cases, this Preconditions of the use case, number (ID) of the use case, step number, operation step description, test data description, expected and actual results, developers and testers, test execution date.
其中,每个子测试用例对应的一个测试用例标识用于唯一识别子测试用例,测试用例标识可以为子测试用例ID,可以为子测试用例的应用场景,也可以为子测试用例的测试步骤,还可以为子测试用例的预期结果,还可以为其他能唯一识别子测试用例的标识,在此不作限定。Wherein, a test case identification corresponding to each sub-test case is used to uniquely identify the sub-test case, and the test case identification can be a sub-test case ID, an application scenario of a sub-test case, or a test step of a sub-test case, or It can be the expected result of the sub-test case, and can also be other identifiers that can uniquely identify the sub-test case, which is not limited here.
其中,目标程序是一组计算机能识别和执行的指令,运行于电子计算机上,满足人们某种需求的信息化工具。Among them, the target program is a set of instructions that can be recognized and executed by a computer, and is an information tool that runs on an electronic computer and meets certain needs of people.
其中,每个子程序对应的一个程序标识可以是子程序的程序ID,也可以是子程序的应用场景,还可以为子程序的功能描述,在此不作限定。Wherein, a program identifier corresponding to each subroutine may be the program ID of the subroutine, the application scenario of the subroutine, or the function description of the subroutine, which is not limited here.
举例说明,表1是一个登录界面测试用例,该登记界面测试用例实现以下功能:用户在地址栏输入相应地址,要求显示登录界面;输入用户名和密码,登录,系统自动校验,并给出相应提示信息;如果用户名或者密码任一信息未输入,登录后系统给出相应提示信息;连续3次未通过验证时,自动关闭浏览器。For example, Table 1 is a test case of the login interface. The test case of the registration interface realizes the following functions: the user enters the corresponding address in the address bar and requests to display the login interface; enters the user name and password, logs in, and the system automatically verifies and gives the corresponding Prompt information; if any information of user name or password is not entered, the system will give corresponding prompt information after login; if the verification fails for 3 consecutive times, the browser will be automatically closed.
表1Table 1
步骤102:获取所述目标测试用例的M个测试用例标识和所述目标程序的N个程序标识。Step 102: Obtain M test case IDs of the target test case and N program IDs of the target program.
进一步地,所述目标测试用例的M个测试用例标识是在所述目标测试用例的编写阶段基于对应的子测试用例命名的测试用例标识,所述N个程序标识是在目标程序编程阶段基于对应的子程序命名的程序标识。Further, the M test case identifiers of the target test case are test case identifiers named based on the corresponding sub-test cases during the writing stage of the target test case, and the N program identifiers are based on the corresponding sub-test case identifiers during the programming stage of the target program. The program ID of the subroutine named.
步骤103:将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果。Step 103: performing keyword matching on each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result.
其中,将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配的具体实现方式可以为:将所述N个程序标识中的程序标识i的关键字与所述M个测试用例标识中的每个测试用例标识的关键字进行关键字匹配,直至所述N个程序标识中所有的程序标识的关键字均与所述M个测试用例标识中的每个测试用例标识的关键字进行关键字匹配;也可以是将所述M个测试用例标识中的测试用例标识j的关键字与所述N个程序标识中的每个程序标识的关键字进行关键字匹配,直至所述M个测试用例标识中所有的测试用例标识的关键字均与所述N个程序标识中的每个程序标识的关键字进行关键字匹配,在此不作限定。Wherein, the specific implementation manner of carrying out keyword matching between each program identifier in the N program identifiers and each test case identifier in the M test case identifiers may be: The keywords of the program identification i are keyword-matched with the keywords of each test case identification in the M test case identifications, until the keywords of all the program identifications in the N program identifications are all matched with the M test case identifications. The keyword of each test case identification in the test case identification carries out keyword matching; It can also be the keyword of the test case identification j in the M test case identifications and each program in the N program identifications The keywords of identification carry out keyword matching, until the keywords of all test case identifications in the M test case identifications all carry out keyword matching with the keywords of each program identification in the N program identifications, where Not limited.
表2Table 2
举例说明,表2为一个获取的登录界面测试用例的测试用例标识与登录界面测应用程序的程序标识一一对应关系表。具体匹配方式可以是将测试用例标识中的“初始页面显示”的关键字“初始页面显示”与程序标识中的“初始页面显示1.0”的关键字“初始页面显示”、“User Log In_1.0”的关键字“User Log In”、“用户名-容错性验证1.0”的关键字“用户名-容错性验证”、“用户名-容错性验证2.0”的关键字“用户名-容错性验证”、“用户名-容错性验证3.0”的关键字“用户名-容错性验证”、“系统登录-成功1.0”的关键字“系统登录-成功”进行关键字匹配,也可以是将程序标识中的“初始页面显示1.0”的关键字“初始页面显示”与测试用例标识中的“初始页面显示”的关键字“初始页面显示”、“用户名录入-验证”的关键字“用户名-录入验证”、“用户名-容错性验证”的关键字“用户名-容错性验证”、“密码-密码录入”的关键字“密码-密码录入”、“系统登录-成功”的关键字“系统登录-成功”进行关键字匹配。For example, Table 2 is a one-to-one correspondence table between the obtained test case identifier of the login interface test case and the program identifier of the login interface test application program. The specific matching method can be to combine the keywords "initial page display" of "initial page display" in the test case identification with the keywords "initial page display" and "User Log In_1.0" of "initial page display 1.0" in the program identification Keyword "User Log In" for "Username - Fault Tolerant Authentication 1.0" Keyword "Username - Fault Tolerant Authentication" "Username - Fault Tolerant Authentication 2.0" Keyword "Username - Fault Tolerant Authentication ", the keyword "username-fault-tolerant authentication" of "username-fault-tolerant authentication 3.0", the keyword "system login-success" of "system login-success 1.0" for keyword matching, or the program identification The keyword "initial page display" of "initial page display 1.0" in the test case identification and the keyword "initial page display" of "initial page display" and the keyword "username- Input verification", "username-fault-tolerant verification" keywords "username-fault-tolerant verification", "password-password entry" keywords "password-password entry", "system login-success" keywords" System Login-Success" for keyword matching.
步骤104:基于所述匹配结果确定测试用例覆盖率。Step 104: Determine test case coverage based on the matching result.
本申请的一实现方式中,所述匹配结果包括Q个匹配成功记录,每个匹配成功记录均包括一个测试用例标识和所述一个测试用例标识匹配的至少一个程序标识,所述基于所述匹配结果确定测试用例覆盖率,包括:In an implementation of the present application, the matching result includes Q successful matching records, and each successful matching record includes a test case identifier and at least one program identifier that matches the one test case identifier, and the matching The results determine test case coverage, including:
确定所述Q个匹配成功记录中记录的Q个测试用例标识,所述Q为大于或等于0且小于或等于M的整数;Determine the Q test case identifiers recorded in the Q matching success records, the Q is an integer greater than or equal to 0 and less than or equal to M;
基于第一公式确定测试用例覆盖率,所述第一公式为:P=Q/M,所述P为测试用例覆盖率。The test case coverage is determined based on a first formula, the first formula is: P=Q/M, and P is the test case coverage.
表3table 3
举例说明,表3为另一个获取的登录界面测试用例的测试用例标识与登录界面测应用程序的程序标识一一对应关系表。根据步骤103,可以得到3个匹配成功记录:测试用例TC1的测试用例标识“初始页面显示”与子程序AP1的程序标识“初始页面显示1.0”匹配成功、测试用例TC3的测试用例标识“用户名-容错性验证”与子程序AP2的程序标识“用户名-容错性验证1.0”、AP3的程序标识“用户名-容错性验证2.0”、AP5的程序标识“用户名-容错性验证3.0”均匹配成功、测试用例TC5的测试用例标识“系统登录-成功”与子程序AP6的程序标识“系统登录-成功1.0”匹配成功。因此,基于第一公式可确定表3中的测试用例覆盖率为60%。For example, Table 3 is a one-to-one correspondence table between the test case identifiers of another obtained login interface test cases and the program identifiers of the login interface test applications. According to step 103, three matching records can be obtained: the test case identifier "initial page display" of the test case TC1 matches successfully with the program identifier "initial page display 1.0" of the subroutine AP1, and the test case identifier "username" of the test case TC3 - Fault Tolerance Verification" and subroutine AP2's program identification "Username - Fault Tolerance Verification 1.0", AP3's program identification "User Name - Fault Tolerance Verification 2.0", AP5's program identification "Username - Fault Tolerance Verification 3.0" The matching is successful, the test case identifier "system login-success" of the test case TC5 and the program identifier "system login-success 1.0" of the subroutine AP6 match successfully. Therefore, based on the first formula, it can be determined that the test case coverage rate in Table 3 is 60%.
可以看出,在本申请实施例中,管理设备先获取目标测试用例和目标测试用例关联的目标程序,目标测试用例的M个子测试用例对应M个测试用例标识和目标程序的N个子程序对应N个程序标识,然后将每个程序标识与每个测试用例标识进行关键字匹配,基于所述匹配结果确定测试用例覆盖率。在将每个程序标识与每个测试用例标识进行关键字匹配的过程中,不需要对目标程序插入探针函数和编译运行,直接匹配测试用例标识和程序标识就可以得到测试用例覆盖率,然后通过测试用例覆盖率可以判断目标程序的完整程度,从而简化软件设计中代码缺陷的检验方法。It can be seen that in the embodiment of the present application, the management device first obtains the target test case and the target program associated with the target test case, and the M sub-test cases of the target test case correspond to the M test case identifiers and the N subroutines of the target program correspond to N Then each program ID is matched with each test case ID, and the test case coverage is determined based on the matching result. In the process of keyword matching each program ID with each test case ID, there is no need to insert probe functions and compile and run the target program, and the test case coverage can be obtained by directly matching the test case ID and program ID, and then The completeness of the target program can be judged by the test case coverage, thus simplifying the inspection method of code defects in software design.
在本申请的一实现方式中,所述管理设备包括输出模块,所述方法还包括:In an implementation manner of the present application, the management device includes an output module, and the method further includes:
通过所述输出模块输出所述Q个测试用例标识、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识和所述测试用例覆盖率。Outputting the Q test case IDs, the M-Q test case IDs in the M test case IDs except the Q test case IDs and the test case coverage rate through the output module.
进一步地,通过所述输出模块输出所述Q个测试用例标识、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识和所述测试用例覆盖率,包括:Further, output the Q test case identifications, the M-Q test case identifications and the test case coverage in the M test case identifications except the Q test case identifications through the output module, including :
确定所述Q个测试用例标识的第一输出参数、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识的第二输出参数和所述测试用例覆盖率的第三输出参数;Determining the first output parameters of the Q test case identifications, the second output parameters of the M-Q test case identifications except the Q test case identifications in the M test case identifications and the test case coverage The third output parameter of ;
通过所述输出模块基于所述第一输出参数输出所述Q个测试用例标识,基于所述第二输出参数输出所述M-Q个测试用例标识,以及基于所述第一输出参数输出所述测试用例覆盖率。Outputting the Q test case identifiers based on the first output parameter through the output module, outputting the M-Q test case identifiers based on the second output parameter, and outputting the test case based on the first output parameter coverage.
其中,第一输出参数、第一输出参数或第三输出参数包括以下至少一种:字体颜色、字体粗细、字体大小、字体背景。第一输出参数、第一输出参数和第三输出参数可以相同,也可以不同,在此不做限定。Wherein, the first output parameter, the first output parameter or the third output parameter includes at least one of the following: font color, font thickness, font size, and font background. The first output parameter, the first output parameter and the third output parameter may be the same or different, which are not limited here.
可以看出,在本申请实施例中,基于第一输出参数输出匹配成功的Q个测试用例标识,基于第二输出参数输出匹配失败的M-Q个测试用例标识,基于第三输出参数输出测试用例覆盖率,不同的输出参数显示不同的部分,以便提醒用户和方便用户后续对测试用例覆盖率进行分析和处理。It can be seen that, in the embodiment of the present application, based on the first output parameter output matching successful Q test case identification, based on the second output parameter output matching failure M-Q test case identification, based on the third output parameter output test case coverage Different output parameters display different parts, so as to remind users and facilitate users to analyze and process test case coverage later.
在本申请的一实现方式中,所述方法还包括:In an implementation of the present application, the method further includes:
在所述测试用例覆盖率低于或等于预设阈值时,向所述管理设备关联的测试人员的第一电子设备发送第一指令,所述第一指令携带所述M-Q个测试用例标识,所述第一指令用于请求所述测试人员从所述M-Q个测试用例标识中选择K个测试用例标识,所述K为大于0且小于或等于M-Q的整数;When the test case coverage rate is lower than or equal to the preset threshold, a first instruction is sent to the first electronic device of the tester associated with the management device, the first instruction carries the M-Q test case identifiers, so The first instruction is used to request the tester to select K test case identifiers from the M-Q test case identifiers, where K is an integer greater than 0 and less than or equal to M-Q;
在接收到所述第一电子设备针对所述第一指令发送的携带所述测试人员选择出的K个测试用例标识的第一响应时,向所述管理设备关联的研发人员的第二电子设备发送第二指令,所述第二指令携带所述选择出的K个测试用例标识,所述第二指令用于通知所述研发人员增加K个子程序至所述目标程序中,所述K个子程序对应的K个子程序标识能够与所述选择出的K个测试用例标识匹配成功。When receiving the first response sent by the first electronic device in response to the first instruction and carrying the K test case identifiers selected by the tester, the second electronic device of the developer associated with the management device Sending a second instruction, the second instruction carrying the selected K test case identifiers, the second instruction is used to notify the R&D personnel to add K subroutines to the target program, and the K subroutines The corresponding K subroutine identifiers can be successfully matched with the selected K test case identifiers.
其中,预设阈值可以是40%、60%、80%或是其他值,在此不作限定。Wherein, the preset threshold may be 40%, 60%, 80% or other values, which are not limited herein.
举例说明,假定预设阈值为80%,如表3所示,测试用例覆盖率为60%,向所述管理设备关联的测试人员的第一电子设备发送第一指令,所述第一指令携带所述2个测试用例标识“用户名录入-验证”和“密码-密码录入”,则所述选择出的K个测试用例标识为“用户名录入-验证”和/或“密码-密码录入”。For example, assuming that the preset threshold is 80%, as shown in Table 3, the test case coverage rate is 60%, and a first instruction is sent to the first electronic device of the tester associated with the management device, and the first instruction carries The two test cases are identified as "username entry-verification" and "password-password entry", and the selected K test cases are identified as "username entry-verification" and/or "password-password entry" .
可以看出,在本申请实施例中,在测试用例覆盖率低于或等于预设阈值时,向管理设备关联的测试人员的第一电子设备发送第一指令,以用于提醒测试人员测试用例覆盖率偏低;向管理设备关联的研发人员的第二电子设备发送第二指令,以用于通知研发人员按照测试人员的要求补充新的子程序,智能的解决了测试用例覆盖率偏低的问题。It can be seen that in the embodiment of the present application, when the test case coverage rate is lower than or equal to the preset threshold, a first instruction is sent to the first electronic device of the tester associated with the management device to remind the tester of the test case Low coverage; send a second instruction to the second electronic device of the R&D personnel associated with the management device to notify the R&D personnel to add new subroutines according to the requirements of the testers, intelligently solving the problem of low test case coverage question.
在本申请的一实现方式中,所述方法还包括:In an implementation of the present application, the method further includes:
在接收到所述第二电子设备针对所述第二指令发送的携带所述研发人员增加的K个子程序的第二响应时,将所述增加的K个子程序添加至所述目标程序中,以及编译包括所述增加的K个子程序的目标程序,以使得所述增加的K个子程序能够被运行。When receiving the second response sent by the second electronic device in response to the second instruction and carrying the K subroutines added by the R&D personnel, adding the K added subroutines to the target program, and compiling the target program including the added K subroutines, so that the added K subroutines can be executed.
可以看出,在本申请实施例中,在接收到第二电子设备针对第二指令发送的携带研发人员增加的K个子程序的第二响应时,将增加的K个子程序添加至目标程序中,以及编译包括增加的K个子程序的目标程序,不需要人为的更新目标程序和编译目标程序,简化了目标程序的更新和编译的流程,从而提升了工作的效率。It can be seen that, in the embodiment of the present application, when receiving the second response sent by the second electronic device for the second instruction and carrying the K subroutines added by the R&D personnel, the added K subroutines are added to the target program, And compiling the target program including the added K subroutines does not need to update the target program and compile the target program artificially, which simplifies the process of updating and compiling the target program, thereby improving work efficiency.
在本申请的一实现方式中,所述编译包括所述K个子程序的目标程序之前,所述方法还包括:In an implementation manner of the present application, before the compiling the target program including the K subroutines, the method further includes:
确定所述匹配结果中Q个测试用例匹配的多个程序标识;Determining multiple program identifiers matched by Q test cases in the matching result;
确定所述多个程序标识对应的多个子程序;determining a plurality of subroutines corresponding to the plurality of program identifiers;
删除所述N个子程序中除所述多个程序标识对应的多个子程序之外的子程序。Deleting subroutines in the N subroutines except for the plurality of subroutines corresponding to the plurality of program identifiers.
举例说明,如表3所示,假定有10个子程序:AP1、AP2、AP3、AP4、AP5、AP6、AP7、AP8、AP9、AP10,3个匹配成功记录中与3个测试用例标识匹配成功的5个程序标识对应的5个子程序分别为:AP1、AP2、AP3、AP5、AP6,则删除子程序AP4、AP7、AP8、AP9、AP10。For example, as shown in Table 3, it is assumed that there are 10 subroutines: AP1, AP2, AP3, AP4, AP5, AP6, AP7, AP8, AP9, AP10, among the 3 successful matching records, the 3 test case identifiers are successfully matched The five subroutines corresponding to the five program identifiers are: AP1, AP2, AP3, AP5, and AP6, and the subroutines AP4, AP7, AP8, AP9, and AP10 are deleted.
可以看出,在本申请实施例中,删除多余的子程序,提升了目标程序源代码的简洁性和可读性,从而也节省了电子设备的内存。It can be seen that in the embodiment of the present application, redundant subroutines are deleted to improve the simplicity and readability of the source code of the target program, thereby saving the memory of the electronic device.
在本申请的一实现方式中,若所述Q个成功记录中有H个匹配成功记录包括的一个测试用例标识与至少两个程序标识匹配,所述编译包括所述K个子程序的目标程序之前,所述方法还包括:In an implementation of the present application, if there are H matching successful records among the Q successful records, a test case identifier included in at least two program identifiers matches, before compiling the target program including the K subroutines, , the method also includes:
确定所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序;Determine at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
获取所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序的编辑时间;Obtain the editing time of at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
将所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序中的目标子程序删除,所述目标子程序删除的编辑时间早于或等于预设时间。Delete the target subroutine in the at least two subroutines corresponding to the at least two program identifiers included in each of the H matching success records, and the editing time of the target subroutine deletion is earlier than or equal to the preset time .
举例说明,如表3所示,5个子程序AP1、AP2、AP3、AP5、AP6中,与测试用例标识“用户名-容错性验证”匹配成功的有3个子程序AP2、AP3、AP5的程序标识,假定AP2的编辑时间为2019年1月18日、AP3的编辑时间为2019年1月20日和AP5的编辑时间为2019年1月23日,预设时间为2019年1月20日,则删除子程序AP2和AP3。For example, as shown in Table 3, among the five subroutines AP1, AP2, AP3, AP5, and AP6, the program identifiers of the three subroutines AP2, AP3, and AP5 successfully match the test case identifier "user name-fault tolerance verification" , assuming that the editing time of AP2 is January 18, 2019, the editing time of AP3 is January 20, 2019, and the editing time of AP5 is January 23, 2019, and the preset time is January 20, 2019, then Delete subroutines AP2 and AP3.
可以看出,在本申请实施例中,基于编辑时间删除目标程序在更新过程中旧版本产生的垃圾,提升了目标程序源代码的简洁性和可读性,从而也节省了电子设备的内存。It can be seen that in the embodiment of the present application, the garbage generated by the old version of the target program during the update process is deleted based on the editing time, which improves the simplicity and readability of the source code of the target program, thereby saving the memory of the electronic device.
与所述图1所示的实施例一致的,请参阅图2,图2是本申请实施例提供的另一种测试用例覆盖率的计算方法的流程示意图,应用于管理设备,该方法包括:Consistent with the embodiment shown in FIG. 1, please refer to FIG. 2. FIG. 2 is a schematic flowchart of another calculation method for test case coverage provided by the embodiment of the present application, which is applied to management devices. The method includes:
步骤201:获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数。Step 201: Acquire the target test case and the target program associated with the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, the target program has N sub-programs, each sub-test A program corresponds to a program identifier, and both the M and the N are integers greater than or equal to 1.
步骤202:获取所述目标测试用例的M个测试用例标识和所述目标程序的N个程序标识。Step 202: Obtain M test case IDs of the target test case and N program IDs of the target program.
步骤203:将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果。Step 203: perform keyword matching on each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result.
步骤204:所述匹配结果包括Q个匹配成功记录,每个匹配成功记录均包括一个测试用例标识和所述一个测试用例标识匹配的至少一个程序标识,确定所述Q个匹配成功记录中记录的Q个测试用例标识,所述Q为大于或等于0且小于或等于M的整数。Step 204: The matching result includes Q successful matching records, and each successful matching record includes a test case ID that matches at least one program ID that matches the one test case ID, and determines the number of records recorded in the Q successful matching records Q test case identifiers, where Q is an integer greater than or equal to 0 and less than or equal to M.
步骤205:基于第一公式确定测试用例覆盖率,所述第一公式为:P=Q/M,所述P为测试用例覆盖率。Step 205: Determine the test case coverage rate based on the first formula, the first formula is: P=Q/M, and the P is the test case coverage rate.
步骤206:所述管理设备包括输出模块,通过所述输出模块输出所述Q个测试用例标识、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识和所述测试用例覆盖率。Step 206: The management device includes an output module, through which the Q test case identifiers, the M-Q test case identifiers except the Q test case identifiers among the M test case identifiers and The test case coverage.
步骤207:在所述测试用例覆盖率低于或等于预设阈值时,向所述管理设备关联的测试人员的第一电子设备发送第一指令,所述第一指令携带所述M-Q个测试用例标识,所述第一指令用于请求所述测试人员从所述M-Q个测试用例标识中选择K个测试用例标识,所述K为大于0且小于或等于M-Q的整数。Step 207: When the test case coverage is lower than or equal to the preset threshold, send a first instruction to the first electronic device of the tester associated with the management device, the first instruction carrying the M-Q test cases identification, the first instruction is used to request the tester to select K test case identifications from the M-Q test case identifications, where K is an integer greater than 0 and less than or equal to M-Q.
步骤208:在接收到所述第一电子设备针对所述第一指令发送的携带所述测试人员选择出的K个测试用例标识的第一响应时,向所述管理设备关联的研发人员的第二电子设备发送第二指令,所述第二指令携带所述选择出的K个测试用例标识,所述第二指令用于通知所述研发人员增加K个子程序至所述目标程序中,所述K个子程序对应的K个子程序标识能够与所述选择出的K个测试用例标识匹配成功。Step 208: When receiving the first response sent by the first electronic device to the first instruction and carrying the K test case identifiers selected by the tester, report to the first response of the developer associated with the management device The second electronic device sends a second instruction, the second instruction carries the selected K test case identifiers, and the second instruction is used to notify the research and development personnel to add K subroutines to the target program, the The K subroutine identifiers corresponding to the K subroutines can successfully match the selected K test case identifiers.
步骤209:确定所述匹配结果中Q个测试用例匹配的多个程序标识。Step 209: Determine multiple program identifiers matched by the Q test cases in the matching results.
步骤210:确定所述多个程序标识对应的多个子程序。Step 210: Determine a plurality of subroutines corresponding to the plurality of program identifiers.
步骤211:删除所述N个子程序中除所述多个程序标识对应的多个子程序之外的子程序。Step 211: Delete subroutines among the N subroutines except for the plurality of subroutines corresponding to the plurality of program identifiers.
步骤212:若所述Q个成功记录中有H个匹配成功记录包括的一个测试用例标识与至少两个程序标识匹配,确定所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序。Step 212: If a test case identifier included in H successful matching records among the Q successful records matches at least two program identifiers, determine at least two test case identifiers included in each of the H successful matching records. The program identifies at least two subroutines to which it corresponds.
步骤213:获取所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序的编辑时间。Step 213: Obtain the editing time of at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records.
步骤214:将所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序中的目标子程序删除,所述目标子程序删除的编辑时间早于或等于预设时间。Step 214: Delete the target subroutine among the at least two subroutines corresponding to the at least two program identifiers included in each of the H successful matching records, and the editing time of the target subroutine deletion is earlier than or equal to preset time.
步骤215:在接收到所述第二电子设备针对所述第二指令发送的携带所述研发人员增加的K个子程序的第二响应时,将所述增加的K个子程序添加至所述目标程序中,以及编译包括所述增加的K个子程序的目标程序,以使得所述增加的K个子程序能够被运行。Step 215: Add the added K subroutines to the target program when receiving the second response sent by the second electronic device in response to the second instruction and carrying the K subroutines added by the R&D personnel , and compiling the target program including the added K subroutines, so that the added K subroutines can be executed.
需要说明的是,本实施例的具体实现过程可参见上述方法实施例所述的具体实现过程,在此不再叙述。It should be noted that, for the specific implementation process of this embodiment, reference may be made to the specific implementation process described in the foregoing method embodiments, which will not be described here again.
与上述图1和图2所示的实施例一致的,请参阅图3,图3是本申请实施例提供的一种电子设备的结构示意图,包括处理器、存储器、通信接口以及一个或多个程序,其中,上述一个或多个程序被存储在上述存储器中,并且被配置由上述处理器执行,上述程序包括用于执行以下步骤的指令:Consistent with the embodiment shown in Figure 1 and Figure 2 above, please refer to Figure 3, Figure 3 is a schematic structural diagram of an electronic device provided by an embodiment of the present application, including a processor, a memory, a communication interface, and one or more A program, wherein the above-mentioned one or more programs are stored in the above-mentioned memory and configured to be executed by the above-mentioned processor, and the above-mentioned program includes instructions for performing the following steps:
获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数;Obtain the target program associated with the target test case and the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, and the target program has N subroutines, each subroutine corresponds to a program identification, the M and the N are both integers greater than or equal to 1;
获取所述目标测试用例的M个测试用例标识和所述目标程序的N个程序标识;Obtain M test case identifiers of the target test case and N program identifiers of the target program;
将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果;performing keyword matching on each program identifier in the N program identifiers and each test case identifier in the M test case identifiers to obtain a matching result;
基于所述匹配结果确定测试用例覆盖率。Test case coverage is determined based on the matching results.
可以看出,在本申请实施例中,管理设备先获取目标测试用例和目标测试用例关联的目标程序,目标测试用例的M个子测试用例对应M个测试用例标识和目标程序的N个子程序对应N个程序标识,然后将每个程序标识与每个测试用例标识进行关键字匹配,基于所述匹配结果确定测试用例覆盖率。在将每个程序标识与每个测试用例标识进行关键字匹配的过程中,不需要对目标程序插入探针函数和编译运行,直接匹配测试用例标识和程序标识就可以得到测试用例覆盖率,然后通过测试用例覆盖率可以判断目标程序的完整程度,从而简化软件设计中代码缺陷的检验方法。It can be seen that in the embodiment of the present application, the management device first obtains the target test case and the target program associated with the target test case, and the M sub-test cases of the target test case correspond to the M test case identifiers and the N subroutines of the target program correspond to N Then each program ID is matched with each test case ID, and the test case coverage is determined based on the matching result. In the process of keyword matching each program ID with each test case ID, there is no need to insert probe functions and compile and run the target program, and the test case coverage can be obtained by directly matching the test case ID and program ID, and then The completeness of the target program can be judged by the test case coverage, thus simplifying the inspection method of code defects in software design.
在本申请的一实现方式中,所述匹配结果包括Q个匹配成功记录,每个匹配成功记录均包括一个测试用例标识和所述一个测试用例标识匹配的至少一个程序标识,在基于所述匹配结果确定测试用例覆盖率方面,上述程序包括具体用于执行以下步骤的指令:In an implementation of the present application, the matching result includes Q successful matching records, and each successful matching record includes a test case identifier and at least one program identifier that matches the one test case identifier, and based on the matching As a result of determining test case coverage, the above procedure includes instructions specifically for performing the following steps:
确定所述Q个匹配成功记录中记录的Q个测试用例标识,所述Q为大于或等于0且小于或等于M的整数;Determine the Q test case identifiers recorded in the Q matching success records, the Q is an integer greater than or equal to 0 and less than or equal to M;
基于第一公式确定测试用例覆盖率,所述第一公式为:P=Q/M,所述P为测试用例覆盖率。The test case coverage is determined based on a first formula, the first formula is: P=Q/M, and P is the test case coverage.
在本申请的一实现方式中,所述管理设备包括输出模块,上述程序包括还用于执行以下步骤的指令:In an implementation manner of the present application, the management device includes an output module, and the above-mentioned program includes instructions for performing the following steps:
通过所述输出模块输出所述Q个测试用例标识、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识和所述测试用例覆盖率。Outputting the Q test case IDs, the M-Q test case IDs in the M test case IDs except the Q test case IDs and the test case coverage rate through the output module.
在本申请的一实现方式中,上述程序包括还用于执行以下步骤的指令:In an implementation of the present application, the above-mentioned program includes instructions for performing the following steps:
在所述测试用例覆盖率低于或等于预设阈值时,向所述管理设备关联的测试人员的第一电子设备发送第一指令,所述第一指令携带所述M-Q个测试用例标识,所述第一指令用于请求所述测试人员从所述M-Q个测试用例标识中确定K个测试用例标识,所述K为大于0且小于或等于M-Q的整数;When the test case coverage rate is lower than or equal to the preset threshold, a first instruction is sent to the first electronic device of the tester associated with the management device, the first instruction carries the M-Q test case identifiers, so The first instruction is used to request the tester to determine K test case identifiers from the M-Q test case identifiers, where K is an integer greater than 0 and less than or equal to M-Q;
在接收到所述第一电子设备针对所述第一指令发送的携带所述测试人员选择出的K个测试用例标识的第一响应时,向所述管理设备关联的研发人员的第二电子设备发送第二指令,所述第二指令携带所述选择出的K个测试用例标识,所述第二指令用于通知所述研发人员增加K个子程序至所述目标程序中,所述K个子程序对应的K个子程序标识能够与所述选择出的K个测试用例标识匹配成功。When receiving the first response sent by the first electronic device in response to the first instruction and carrying the K test case identifiers selected by the tester, the second electronic device of the developer associated with the management device Sending a second instruction, the second instruction carrying the selected K test case identifiers, the second instruction is used to notify the R&D personnel to add K subroutines to the target program, and the K subroutines The corresponding K subroutine identifiers can be successfully matched with the selected K test case identifiers.
在本申请的一实现方式中,上述程序包括还用于执行以下步骤的指令:In an implementation of the present application, the above-mentioned program includes instructions for performing the following steps:
在接收到所述第二电子设备针对所述第二指令发送的携带所述研发人员增加的K个子程序的第二响应时,将所述增加的K个子程序添加至所述目标程序中,以及编译包括所述增加的K个子程序的目标程序,以使得所述增加的K个子程序能够被运行。When receiving the second response sent by the second electronic device in response to the second instruction and carrying the K subroutines added by the R&D personnel, adding the K added subroutines to the target program, and compiling the target program including the added K subroutines, so that the added K subroutines can be executed.
在本申请的一实现方式中,在编译包括所述K个子程序的目标程序之前,上述程序包括还用于执行以下步骤的指令:In an implementation manner of the present application, before compiling the target program including the K subroutines, the above program includes instructions for performing the following steps:
确定所述匹配结果中Q个测试用例匹配的多个程序标识;Determining multiple program identifiers matched by Q test cases in the matching result;
确定所述多个程序标识对应的多个子程序;determining a plurality of subroutines corresponding to the plurality of program identifiers;
删除所述N个子程序中除所述多个程序标识对应的多个子程序之外的子程序。Deleting subroutines in the N subroutines except for the plurality of subroutines corresponding to the plurality of program identifiers.
在本申请的一实现方式中,若所述Q个成功记录中有H个匹配成功记录包括的一个测试用例标识与至少两个程序标识匹配,在编译包括所述K个子程序的目标程序之前,上述程序包括还用于执行以下步骤的指令:In an implementation of the present application, if there are H matching successful records among the Q successful records, a test case identifier included in at least two program identifiers matches, before compiling the target program including the K subroutines, The above program includes instructions to also perform the following steps:
确定所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序;Determine at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
获取所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序的编辑时间;Obtain the editing time of at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
将所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序中的目标子程序删除,所述目标子程序删除的编辑时间早于或等于预设时间。Delete the target subroutine in the at least two subroutines corresponding to the at least two program identifiers included in each of the H matching success records, and the editing time of the target subroutine deletion is earlier than or equal to the preset time .
需要说明的是,本实施例的具体实现过程可参见上述方法实施例所述的具体实现过程,在此不再叙述。It should be noted that, for the specific implementation process of this embodiment, reference may be made to the specific implementation process described in the foregoing method embodiments, which will not be described here again.
上述实施例主要从方法侧执行过程的角度对本申请实施例的方案进行了介绍。可以理解的是,电子设备为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本申请能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。The foregoing embodiments mainly introduce the solutions of the embodiments of the present application from the perspective of executing a process on the method side. It can be understood that, in order to realize the above functions, the electronic device includes hardware structures and/or software modules corresponding to each function. Those skilled in the art should easily realize that the present application can be implemented in the form of hardware or a combination of hardware and computer software in combination with the units and algorithm steps of each example described in the embodiments disclosed herein. Whether a certain function is executed by hardware or computer software drives hardware depends on the specific application and design constraints of the technical solution. Skilled artisans may use different methods to implement the described functions for each specific application, but such implementation should not be regarded as exceeding the scope of the present application.
本申请实施例可以根据所述方法示例对电子设备进行功能单元的划分,例如,可以对应各个功能划分各个功能单元,也可以将两个或两个以上的功能集成在一个处理单元中。所述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。需要说明的是,本申请实施例中对单元的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。The embodiment of the present application may divide the electronic device into functional units according to the method example, for example, each functional unit may be divided corresponding to each function, or two or more functions may be integrated into one processing unit. The integrated units can be implemented in the form of hardware or in the form of software functional units. It should be noted that the division of units in the embodiment of the present application is schematic, and is only a logical function division, and there may be another division manner in actual implementation.
下面为本申请装置实施例,本申请装置实施例用于执行本申请方法实施例所实现的方法。请参阅图4,本申请实施例提供的一种测试用例覆盖率的计算装置,应用于管理设备,该测试用例覆盖率的计算装置包括:The following are the device embodiments of the present application, and the device embodiments of the present application are used to implement the methods implemented by the method embodiments of the present application. Please refer to Fig. 4, a test case coverage calculation device provided by an embodiment of the present application is applied to a management device, and the test case coverage calculation device includes:
获取单元401,用于获取目标测试用例和所述目标测试用例关联的目标程序,所述目标测试用例包含M个子测试用例,每个子测试用例对应一个测试用例标识,所述目标程序有N个子程序,每个子程序对应一个程序标识,所述M和所述N均为大于或等于1的整数;获取所述目标测试用例的每个子测试用例的测试用例标识和所述目标程序的每个子程序的程序标识;The obtaining unit 401 is used to obtain the target test case and the target program associated with the target test case, the target test case includes M sub-test cases, each sub-test case corresponds to a test case identifier, and the target program has N sub-programs , each subroutine corresponds to a program identification, and the M and the N are integers greater than or equal to 1; obtain the test case identification of each subroutine of the target test case and the test case identification of each subroutine of the target program Program ID;
匹配单元402,用于将所述N个程序标识中的每个程序标识与所述M个测试用例标识中的每个测试用例标识进行关键字匹配,以得到匹配结果;A matching unit 402, configured to perform keyword matching between each program identifier in the N program identifiers and each test case identifier in the M test case identifiers, to obtain a matching result;
确定单元403,用于基于所述匹配结果确定测试用例覆盖率。A determining unit 403, configured to determine a test case coverage rate based on the matching result.
可以看出,在本申请实施例中,管理设备先获取目标测试用例和目标测试用例关联的目标程序,目标测试用例的M个子测试用例对应M个测试用例标识和目标程序的N个子程序对应N个程序标识,然后将每个程序标识与每个测试用例标识进行关键字匹配,基于所述匹配结果确定测试用例覆盖率。在将每个程序标识与每个测试用例标识进行关键字匹配的过程中,不需要对目标程序插入探针函数和编译运行,直接匹配测试用例标识和程序标识就可以得到测试用例覆盖率,然后通过测试用例覆盖率可以判断目标程序的完整程度,从而简化软件设计中代码缺陷的检验方法。It can be seen that in the embodiment of the present application, the management device first obtains the target test case and the target program associated with the target test case, and the M sub-test cases of the target test case correspond to the M test case identifiers and the N subroutines of the target program correspond to N Then each program ID is matched with each test case ID, and the test case coverage is determined based on the matching result. In the process of keyword matching each program ID with each test case ID, there is no need to insert probe functions and compile and run the target program, and the test case coverage can be obtained by directly matching the test case ID and program ID, and then The completeness of the target program can be judged by the test case coverage, thus simplifying the inspection method of code defects in software design.
在本申请的一实现方式中,所述匹配结果包括Q个匹配成功记录,每个匹配成功记录均包括一个测试用例标识和所述一个测试用例标识匹配的一个程序标识,在基于所述匹配结果确定测试用例覆盖率方面,所述确定单元403具体用于:In an implementation of the present application, the matching result includes Q successful matching records, and each successful matching record includes a test case identifier and a program identifier that matches the one test case identifier, and based on the matching result In terms of determining test case coverage, the determination unit 403 is specifically used for:
确定所述Q个匹配成功记录中记录的Q个测试用例标识,所述Q为大于或等于0且小于或等于M的整数;基于第一公式确定测试用例覆盖率,所述第一公式为:P=Q/M,所述P为测试用例覆盖率。Determine the Q test case identifications recorded in the Q matching success records, the Q is an integer greater than or equal to 0 and less than or equal to M; determine the test case coverage based on the first formula, the first formula is: P=Q/M, the P is the test case coverage.
在本申请的一实现方式中,所述管理设备包括输出模块,所述装置还包括输出单元404,用于:In an implementation manner of the present application, the management device includes an output module, and the device further includes an output unit 404, configured to:
通过所述输出模块输出所述Q个测试用例标识、所述M个测试用例标识中除所述Q个测试用例标识之外的M-Q个测试用例标识和所述测试用例覆盖率。Outputting the Q test case IDs, the M-Q test case IDs in the M test case IDs except the Q test case IDs and the test case coverage rate through the output module.
在本申请的一实现方式中,所述装置还包括通信单元405,用于:In an implementation of the present application, the device further includes a communication unit 405, configured to:
在所述测试用例覆盖率低于或等于预设阈值时,向所述管理设备关联的测试人员的第一电子设备发送第一指令,所述第一指令携带所述M-Q个测试用例标识,所述第一指令用于请求所述测试人员从所述M-Q个测试用例标识中确定K个测试用例标识,所述K为大于0且小于或等于M-Q的整数;When the test case coverage rate is lower than or equal to the preset threshold, a first instruction is sent to the first electronic device of the tester associated with the management device, the first instruction carries the M-Q test case identifiers, so The first instruction is used to request the tester to determine K test case identifiers from the M-Q test case identifiers, where K is an integer greater than 0 and less than or equal to M-Q;
在接收到所述第一电子设备针对所述第一指令发送的携带所述测试人员选择出的K个测试用例标识的第一响应时,向所述管理设备关联的研发人员的第二电子设备发送第二指令,所述第二指令携带所述选择出的K个测试用例标识,所述第二指令用于通知所述研发人员增加K个子程序至所述目标程序中,所述K个子程序对应的K个子程序标识能够与所述选择出的K个测试用例标识匹配成功。When receiving the first response sent by the first electronic device in response to the first instruction and carrying the K test case identifiers selected by the tester, the second electronic device of the developer associated with the management device Sending a second instruction, the second instruction carrying the selected K test case identifiers, the second instruction is used to notify the R&D personnel to add K subroutines to the target program, and the K subroutines The corresponding K subroutine identifiers can be successfully matched with the selected K test case identifiers.
在本申请的一实现方式中,所述装置还包括添加编译单元406,用于:In an implementation of the present application, the device further includes an adding compiling unit 406, configured to:
在接收到所述第二电子设备针对所述第二指令发送的携带所述研发人员增加的K个子程序的第二响应时,将所述增加的K个子程序添加至所述目标程序中,以及编译包括所述增加的K个子程序的目标程序,以使得所述增加的K个子程序能够被运行。When receiving the second response sent by the second electronic device in response to the second instruction and carrying the K subroutines added by the R&D personnel, adding the K added subroutines to the target program, and compiling the target program including the added K subroutines, so that the added K subroutines can be executed.
在本申请的一实现方式中,在编译包括所述K个子程序的目标程序之前,所述确定单元403,还用于确定所述匹配结果中Q个测试用例匹配的多个程序标识;确定所述多个程序标识对应的多个子程序;In an implementation manner of the present application, before compiling the target program including the K subroutines, the determining unit 403 is further configured to determine a plurality of program identifiers matched by the Q test cases in the matching result; determine the A plurality of subroutines corresponding to the plurality of program identifiers;
所述装置还包括删除单元407,用于删除所述N个子程序中除所述多个程序标识对应的多个子程序之外的子程序。The apparatus further includes a deleting unit 407, configured to delete subprograms among the N subprograms except the multiple subprograms corresponding to the multiple program identifiers.
在本申请的一实现方式中,若所述Q个成功记录中有H个匹配成功记录包括的一个测试用例标识与至少两个程序标识匹配,在编译包括所述K个子程序的目标程序之前,所述确定单元403,还用于确定所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序;In an implementation of the present application, if there are H matching successful records among the Q successful records, a test case identifier included in at least two program identifiers matches, before compiling the target program including the K subroutines, The determining unit 403 is further configured to determine at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
所述获取单元401,还用于获取所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序的编辑时间;The acquiring unit 401 is further configured to acquire the editing time of at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records;
所述删除单元407,还用于将所述H个匹配成功记录中每个匹配成功记录包括的至少两个程序标识对应的至少两个子程序中的目标子程序删除,所述目标子程序删除的编辑时间早于或等于预设时间。The deleting unit 407 is further configured to delete target subprograms among at least two subprograms corresponding to at least two program identifiers included in each of the H successful matching records, and the deleted target subprograms The editing time is earlier than or equal to the preset time.
需要说明的是,获取单元401、匹配单元402、确定单元403、输出单元404、添加编译单元406和删除单元407可通过处理器实现,通信单元405可通过通信接口。It should be noted that the acquiring unit 401 , the matching unit 402 , the determining unit 403 , the output unit 404 , the adding and compiling unit 406 and the deleting unit 407 can be implemented by a processor, and the communication unit 405 can be implemented by a communication interface.
本申请实施例还提供一种计算机存储介质,其中,该计算机存储介质存储用于存储计算机程序,该计算机程序被处理器执行如上述方法实施例中记载的任一方法的部分或全部步骤。An embodiment of the present application further provides a computer storage medium, wherein the computer storage medium is used to store a computer program, and the computer program is used by a processor to execute some or all steps of any method described in the above method embodiments.
本申请实施例还提供一种计算机程序产品,上述计算机程序产品包括存储了计算机程序的非瞬时性计算机可读存储介质,上述计算机程序可操作来使计算机执行如上述方法实施例中记载的任一方法的部分或全部步骤。该计算机程序产品可以为一个软件安装包。An embodiment of the present application also provides a computer program product, the computer program product includes a non-transitory computer-readable storage medium storing a computer program, and the computer program is operable to enable the computer to execute any one of the methods described in the above method embodiments. Some or all steps of the method. The computer program product may be a software installation package.
需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本申请所必须的。It should be noted that for the foregoing method embodiments, for the sake of simple description, they are expressed as a series of action combinations, but those skilled in the art should know that the present application is not limited by the described action sequence. Depending on the application, certain steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification belong to preferred embodiments, and the actions and modules involved are not necessarily required by this application.
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。In the foregoing embodiments, the descriptions of each embodiment have their own emphases, and for parts not described in detail in a certain embodiment, reference may be made to relevant descriptions of other embodiments.
在本申请所提供的几个实施例中,应该理解到,所揭露的装置,可通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如上述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed device can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the above units is only a logical function division. In actual implementation, there may be other division methods, for example, multiple units or components can be combined or integrated. to another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical or other forms.
上述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.
上述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储器中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储器中,包括若干指令用以使得一台计算机设备(可为个人计算机、服务器或者网络设备等)执行本申请各个实施例上述方法的全部或部分步骤。而前述的存储器包括:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。If the above-mentioned integrated units are realized in the form of software function units and sold or used as independent products, they can be stored in a computer-readable memory. Based on this understanding, the technical solution of the present application is essentially or part of the contribution to the prior art, or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a memory. Several instructions are included to make a computer device (which may be a personal computer, server or network device, etc.) execute all or part of the steps of the above-mentioned methods in various embodiments of the present application. The aforementioned memory includes: U disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disk or optical disk and other media that can store program codes.
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储器中,存储器可以包括:闪存盘、只读存储器(英文:Read-Only Memory,简称:ROM)、随机存取器(英文:Random Access Memory,简称:RAM)、磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable memory, and the memory can include: a flash disk , Read-only memory (English: Read-Only Memory, abbreviated: ROM), random access device (English: Random Access Memory, abbreviated: RAM), magnetic disk or optical disk, etc.
以上对本申请实施例进行了详细介绍,本文中应用了具体个例对本申请的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本申请的方法及其核心思想;同时,对于本领域的一般技术人员,依据本申请的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本申请的限制。The embodiments of the present application have been introduced in detail above, and specific examples have been used in this paper to illustrate the principles and implementation methods of the present application. The descriptions of the above embodiments are only used to help understand the methods and core ideas of the present application; meanwhile, for Those skilled in the art will have changes in specific implementation methods and application scopes based on the ideas of the present application. In summary, the contents of this specification should not be construed as limiting the present application.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910421939.8A CN110209576A (en) | 2019-05-21 | 2019-05-21 | The calculation method and relevant device of test case coverage rate |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910421939.8A CN110209576A (en) | 2019-05-21 | 2019-05-21 | The calculation method and relevant device of test case coverage rate |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110209576A true CN110209576A (en) | 2019-09-06 |
Family
ID=67787906
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910421939.8A Pending CN110209576A (en) | 2019-05-21 | 2019-05-21 | The calculation method and relevant device of test case coverage rate |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN110209576A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111400189A (en) * | 2020-03-25 | 2020-07-10 | 平安银行股份有限公司 | Code coverage monitoring method, device, electronic device and storage medium |
CN111639031A (en) * | 2020-06-01 | 2020-09-08 | 电信科学技术第十研究所有限公司 | Coverage evaluation method and device based on test data |
CN112380125A (en) * | 2020-11-16 | 2021-02-19 | 中信银行股份有限公司 | Test case recommendation method and device, electronic equipment and readable storage medium |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100095274A1 (en) * | 2008-10-10 | 2010-04-15 | American Express Travel Related Services Company, Inc. | System, Computer Program, and Method for a Static Code Coverage Analyzer for Computer Programs |
US20150161026A1 (en) * | 2013-12-09 | 2015-06-11 | International Business Machines Corporation | System and method for determining test coverage |
US20160034382A1 (en) * | 2014-08-01 | 2016-02-04 | Unisys Corporation | Automated regression test case selector and black box test coverage tool for product testing |
CN107797923A (en) * | 2017-10-10 | 2018-03-13 | 平安科技(深圳)有限公司 | Code coverage rate analysis method and application server |
CN108038052A (en) * | 2017-11-27 | 2018-05-15 | 平安科技(深圳)有限公司 | Automatic test management method, device, terminal device and storage medium |
CN109308263A (en) * | 2018-09-29 | 2019-02-05 | 北京云测信息技术有限公司 | A kind of small routine test method, device and equipment |
CN109766263A (en) * | 2018-12-15 | 2019-05-17 | 深圳壹账通智能科技有限公司 | Automated test analysis and processing method, device, computer equipment and storage medium |
-
2019
- 2019-05-21 CN CN201910421939.8A patent/CN110209576A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100095274A1 (en) * | 2008-10-10 | 2010-04-15 | American Express Travel Related Services Company, Inc. | System, Computer Program, and Method for a Static Code Coverage Analyzer for Computer Programs |
US20150161026A1 (en) * | 2013-12-09 | 2015-06-11 | International Business Machines Corporation | System and method for determining test coverage |
US20160034382A1 (en) * | 2014-08-01 | 2016-02-04 | Unisys Corporation | Automated regression test case selector and black box test coverage tool for product testing |
CN107797923A (en) * | 2017-10-10 | 2018-03-13 | 平安科技(深圳)有限公司 | Code coverage rate analysis method and application server |
CN108038052A (en) * | 2017-11-27 | 2018-05-15 | 平安科技(深圳)有限公司 | Automatic test management method, device, terminal device and storage medium |
CN109308263A (en) * | 2018-09-29 | 2019-02-05 | 北京云测信息技术有限公司 | A kind of small routine test method, device and equipment |
CN109766263A (en) * | 2018-12-15 | 2019-05-17 | 深圳壹账通智能科技有限公司 | Automated test analysis and processing method, device, computer equipment and storage medium |
Non-Patent Citations (2)
Title |
---|
TEEMU KANSTRÉN: "Towards a deeper understanding of test coverage", 《JOURNAL OF SOFTWARE MAINTENANCE AND EVOLUTION: RESEARCH AND PRACTICE》, vol. 20, no. 1, 28 February 2008 (2008-02-28), pages 59 - 76 * |
董昕;牟永敏;于秀山;: "代码覆盖与功能覆盖映射方法探究", 数据通信, no. 03, 28 June 2016 (2016-06-28), pages 9 - 17 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111400189A (en) * | 2020-03-25 | 2020-07-10 | 平安银行股份有限公司 | Code coverage monitoring method, device, electronic device and storage medium |
CN111639031A (en) * | 2020-06-01 | 2020-09-08 | 电信科学技术第十研究所有限公司 | Coverage evaluation method and device based on test data |
CN111639031B (en) * | 2020-06-01 | 2023-06-30 | 电信科学技术第十研究所有限公司 | Coverage evaluation method and device based on test data |
CN112380125A (en) * | 2020-11-16 | 2021-02-19 | 中信银行股份有限公司 | Test case recommendation method and device, electronic equipment and readable storage medium |
CN112380125B (en) * | 2020-11-16 | 2024-04-26 | 中信银行股份有限公司 | Recommendation method and device for test cases, electronic equipment and readable storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108628743B (en) | Application program testing method, device, equipment and storage medium | |
WO2018000607A1 (en) | Method and electronic apparatus for identifying test case failure causes | |
CN106484606A (en) | Method and apparatus submitted to by a kind of code | |
CN110830234B (en) | User traffic distribution method and device | |
CN110209576A (en) | The calculation method and relevant device of test case coverage rate | |
CN108920370B (en) | Compatibility problem detection method, device and equipment | |
CN108563572A (en) | A kind of regression testing method, device and server | |
CN111124480B (en) | Method and device for generating application program package, electronic equipment and storage medium | |
CN107632901A (en) | A kind of self-repair method and device of application program operation exception | |
CN109408309B (en) | Multi-terminal testing method and device | |
CN114610341A (en) | Production line flashing method, device, electronic device, chip and storage medium | |
CN114448848A (en) | Test method, device, electronic device and storage medium for a switch | |
CN108170600A (en) | The coverage rate statistical method of front-end code test, apparatus and system | |
CN102981956B (en) | Method, device and program modulating system that overlay symbol table is set up and searched | |
CN113051178A (en) | Test data construction method, device, equipment and medium | |
CN114185804B (en) | Interface testing method and device and terminal equipment | |
CN106294129A (en) | Code coverage method of testing and device | |
CN115016775A (en) | Interface simulation method and device, storage medium and electronic device | |
CN108156053B (en) | Service processing method, device, system and server | |
CN110609786A (en) | Software testing method and device, computer equipment and storage medium | |
CN112561690B (en) | Method, system, equipment and storage medium for testing credit card staged service interface | |
CN114116497A (en) | Test method and device, server | |
CN115510182A (en) | User complaint determination method, equipment, storage medium and device | |
CN111190824B (en) | Monitoring method, device, terminal equipment and storage medium | |
CN112115060A (en) | Audio test method and system based on terminal |
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 | ||
WD01 | Invention patent application deemed withdrawn after publication | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20190906 |