CN108920353A - A kind of test method, device and electronic equipment - Google Patents

A kind of test method, device and electronic equipment Download PDF

Info

Publication number
CN108920353A
CN108920353A CN201810288883.9A CN201810288883A CN108920353A CN 108920353 A CN108920353 A CN 108920353A CN 201810288883 A CN201810288883 A CN 201810288883A CN 108920353 A CN108920353 A CN 108920353A
Authority
CN
China
Prior art keywords
test case
test
case
matrix
demand number
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
Application number
CN201810288883.9A
Other languages
Chinese (zh)
Inventor
张震
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhengzhou Yunhai Information Technology Co Ltd
Original Assignee
Zhengzhou Yunhai Information Technology Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by Zhengzhou Yunhai Information Technology Co Ltd filed Critical Zhengzhou Yunhai Information Technology Co Ltd
Priority to CN201810288883.9A priority Critical patent/CN108920353A/en
Publication of CN108920353A publication Critical patent/CN108920353A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3684Test management for test design, e.g. generating new test cases

Abstract

The embodiment of the present invention provides a kind of test method, device and electronic equipment, according to test case requirement matrix, calculates the demand number of each test case, the test case requirement matrix is for describing the testing requirement that test case is covered;When being greater than threshold value there are the demand number of at least one test case, select the maximum test case of demand number as target detection use-case;According to target detection use-case, the test case requirement matrix is marked, and according to the test case requirement matrix after label, updates the demand number of each test case;Wherein, all target detection use-cases selected are for testing.By testing requirement matrix, the test case of cover-most testing requirement is filtered out, can guarantee to be tested using less test case cover-most testing requirement in this way, prevent retest and test leakage, effectively increase testing efficiency and precision.

Description

A kind of test method, device and electronic equipment
Technical field
The present invention relates to the field of test technology, more particularly to a kind of test method, device and electronic equipment.
Background technique
Software test is the important link of soft project, it be directly related to quality, development progress and the project of software at This.With the development of software technology and coding techniques, while the efficiency of software design and coding is improved, software test Workload and work accounting are also continuously improved in the life cycle of entire software development.
In software test, regression test generally takes up higher testing cost.In common regression test, old code After the completion of modification, need to re-start test to confirm modification without introducing new mistake or other codes being caused to generate mistake. The execution of regression test needs to rely on test case, and current way is by software engineer by hand from system testing use-case In select test case, carry out regression test.
However, inventors discovered through research that, in the implementation process of regression test, the mode of hand picking test case is very It is easy the unrelated test case of multiselect, causes testing efficiency low;Alternatively, the test case that selection is less, causes test to be omitted, Measuring accuracy is poor.Therefore, how a kind of test method be provided, improve testing efficiency and precision be those skilled in the art urgently Technical problem to be solved.
Summary of the invention
In view of the foregoing deficiencies of prior art, the purpose of the present invention is to provide a kind of test method, device and electricity Sub- equipment, for solving the problems, such as that testing efficiency is low in the prior art and low precision.
In order to achieve the above objects and other related objects, according to the first aspect of the invention, the embodiment of the present invention provides one Kind test method, this approach includes the following steps:
According to test case requirement matrix, the demand number of each test case is calculated, the test case requirement matrix is used In the testing requirement that description test case is covered;
When there are the demand number of at least one test case be greater than threshold value when, select the maximum test case of demand number as Target detection use-case;
According to target detection use-case, the test case requirement matrix is marked, and according to the test case demand after label Matrix updates the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
Optionally, described according to test case requirement matrix, the demand number for calculating each test case includes:
When the corresponding test case of the row of the test case requirement matrix, the column of the test case requirement matrix are corresponding to be surveyed Examination demand, and when the matrix element of test case and testing requirement strong correlation is the first element, add up the test case demand First element of every row of matrix, the demand number as corresponding test case.
Optionally, according to the target detection use-case, the test case requirement matrix is marked, including:
It is second element by the first rubidium marking of target detection use-case, and by second in test case requirement matrix The corresponding all matrix elements arranged of element are labeled as second element.
Optionally, the test case requirement matrix according to after label updates the demand number of each test case, packet It includes:
Add up the test case requirement matrix every row the first element, update the demand number of corresponding test case.
Optionally, which further includes:
When the demand number of each test case is respectively less than or is equal to threshold value, test set is determined, according to the test set Test;Wherein, the test set includes all target detection use-cases selected.
According to the second aspect of the invention, the embodiment of the present invention also provides a kind of test device, which includes:
Computing module calculates the demand number of each test case according to test case requirement matrix, and the test case needs Ask matrix for describing the testing requirement that test case is covered;
Selecting module selects the maximum survey of demand number when being greater than threshold value there are the demand number of at least one test case Example is tried out as target detection use-case;
Update module marks the test case requirement matrix according to target detection use-case, and according to the test after label Use-case requirement matrix updates the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
Optionally, the computing module is also used to,
When the corresponding test case of the row of the test case requirement matrix, the column of the test case requirement matrix are corresponding to be surveyed Examination demand, and when the matrix element of test case and testing requirement strong correlation is the first element, add up the test case demand First element of every row of matrix, the demand number as corresponding test case.
Optionally, the update module is also used to,
It is second element by the first rubidium marking of target detection use-case, and by second in test case requirement matrix The corresponding all matrix elements arranged of element are labeled as second element.
Optionally, which further includes that collection modules are used for,
When the demand number of each test case is respectively less than or is equal to threshold value, test set is determined, according to the test set Test;Wherein, the test set includes all target detection use-cases selected.
According to the third aspect of the invention we, the embodiment of the present invention also provides a kind of electronic equipment, and the electronic equipment includes At least one processor;And
The memory being connect at least one described processor communication;Wherein,
The memory is stored with the instruction that can be executed by one processor, and described instruction is by described at least one It manages device to execute, so that at least one described processor can:
According to test case requirement matrix, the demand number of each test case is calculated, the test case requirement matrix is used In the testing requirement that description test case is covered;
When there are the demand number of at least one test case be greater than threshold value when, select the maximum test case of demand number as Target detection use-case;
According to target detection use-case, the test case requirement matrix is marked, and according to the test case demand after label Matrix updates the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
As described above, a kind of test method, device and electronic equipment provided in an embodiment of the present invention, have below beneficial to effect Fruit:According to test case requirement matrix, the demand number of each test case is calculated, the test case requirement matrix is for describing The testing requirement that test case is covered;When being greater than threshold value there are the demand number of at least one test case, demand number is selected Maximum test case is as target detection use-case;According to target detection use-case, the test case requirement matrix, and root are marked According to the test case requirement matrix after label, the demand number of each test case is updated;Wherein, all target detections selected Use-case is for testing.By testing requirement matrix, the test case of cover-most testing requirement is filtered out, can guarantee to make in this way It is tested with less test case cover-most testing requirement, prevents retest and test leakage, effectively increase Testing efficiency and precision.
Detailed description of the invention
The drawings herein are incorporated into the specification and forms part of this specification, and shows and meets implementation of the invention Example, and be used to explain the principle of the present invention together with specification.
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to be briefly described, it should be apparent that, for those of ordinary skill in the art Speech, without any creative labor, is also possible to obtain other drawings based on these drawings.
Fig. 1 is a kind of flow diagram of test method provided in an embodiment of the present invention;
Fig. 2 is a kind of schematic diagram of test case requirement matrix provided in an embodiment of the present invention;
Fig. 3 is the schematic diagram of test case requirement matrix after a kind of label provided in an embodiment of the present invention;
Fig. 4 is the flow diagram of another test method provided in an embodiment of the present invention;
Fig. 5 is a kind of structural schematic diagram of test device provided in an embodiment of the present invention;
Fig. 6 is a kind of structural schematic diagram of electronic equipment for executing test method provided in an embodiment of the present invention.
Specific embodiment
Technical solution in order to enable those skilled in the art to better understand the present invention, below in conjunction with of the invention real The attached drawing in example is applied, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that described implementation Example is only a part of the embodiment of the present invention, instead of all the embodiments.Based on the embodiments of the present invention, this field is common Technical staff's every other embodiment obtained without making creative work, all should belong to protection of the present invention Range.
Fig. 1 is please referred to Fig. 6.It should be noted that diagram provided in the present embodiment only illustrates this in a schematic way The basic conception of invention, only shown in diagram then with related component in the present invention rather than package count when according to actual implementation Mesh, shape and size are drawn, when actual implementation kenel, quantity and the ratio of each component can arbitrarily change for one kind, and its Assembly layout kenel may also be increasingly complex.
It is a kind of flow diagram of test method provided in an embodiment of the present invention, as shown in Figure 1, of the invention referring to Fig. 1 Implement the process for being illustrated screening test cases:
Step S101:According to test case requirement matrix, the demand number of each test case is calculated, the test case needs Ask matrix for describing the testing requirement that test case is covered.
The test case requirement matrix characterizes the corresponding relationship of test case Yu its coverage test demand.Referring to figure 2, it is a kind of schematic diagram of test case requirement matrix provided in an embodiment of the present invention, as shown in Fig. 2, the test case demand square Battle array can be the matrix of M × N, and wherein M and N is natural number.In above-mentioned test case requirement matrix, the row in matrix is corresponded to Test case, matrix include M row and respectively correspond test case 1, test case 2, until test case M;Column pair in matrix Testing requirement is answered, matrix includes N column and respectively corresponds demand 1, demand 2, until demand N.
It, can be will be in matrix when test case can be used in meeting testing requirement moreover, in embodiments of the present invention The element of corresponding position is set as the first element.In one exemplary embodiment, first element can be " 1 ";For surveying Example 1 on probation can be by the 1st row the 2nd in matrix when the test case 1 can satisfy demand 2, demand N-2 and demand N-1 The element of the element of column, the element of the 1st row N-2 column and the 1st row N-1 column is disposed as the first element " 1 ".In addition, right It can be set to " 0 " in the matrix element that test case is unable to meet demand, in this way, test case each for M is correspondingly arranged Corresponding column element, available test case requirement matrix as shown in Figure 2.
Certainly it should be noted that the form of above-mentioned test case requirement matrix is only an exemplary embodiment, specific Test case can also be corresponded to for the column in any other form such as matrix when implementation, the corresponding testing requirement of the row in matrix, And matrix element can also be any other numerical value, repeat no more in embodiments of the present invention.
Test provided in an embodiment of the present invention is discussed in detail by taking test case requirement matrix shown in Fig. 2 as an example in the present invention Method.
In above-mentioned test case requirement matrix, the corresponding test case of row, the column of the test case requirement matrix are corresponded to Testing requirement, and when the matrix element of test case and testing requirement strong correlation is the first element, the test case that adds up needs The first element for seeking every row of matrix, the demand number as corresponding test case.Under the first performance, test is used Example 1, since test case 1 can satisfy demand 2, demand N-2 and demand N-1, and the element of corresponding position is in matrix First element, then add up this 3 first elements, so that demand number=1+1+1=3 of test case 1, characterization test be calculated Use-case 1 can cover demand 1, demand N-2 and demand N-1 and amount to 3 demands.Under second of performance, due to test Label is 0 " to the demand that use-case can not cover in test case requirement matrix, therefore, in calculating process, can be added up Column element corresponding to test case is to obtain the demand number of corresponding test case, similarly for test case 1, test case 1 Demand number=0+1+0+ ...+1+1+0=3.
Step S102:When being greater than threshold value there are the demand number of at least one test case, the maximum survey of demand number is selected Example is tried out as target detection use-case.
By the calculating of step S101, the demand number of test case 1 is 3, and the demand number of test case 2 is 4, test case 3 demand number is 0.In order to select target detection use-case, in one exemplary embodiment, which can be preset as " 0 ";This Sample, since the demand number of test case 1 and the demand number of test case 2 are all larger than the threshold value, the demand number of test case 3 is equal to The threshold value, therefore continue that the maximum test case of demand number is selected to use as target detection from test case 1 and test case 2 Example;Further, the demand number of test case 2 is 4 and maximum, therefore target detection use-case is test case 2.
In addition, can be used from the multiple test when the demand number there are multiple test cases is identical and when being maximum Arbitrarily select a test case as target detection use-case in example;Alternatively, according to the access times of target detection use-case, from institute The test case for selecting access times most in multiple test cases is stated as target detection use-case.
Step S103:According to target detection use-case, the test case requirement matrix is marked, and according to the test after label Use-case requirement matrix updates the demand number of each test case;Wherein, all target detection use-cases selected are for testing.
According to the target detection use-case that step S102 is determined, which is test case 2, then further marks Column element corresponding to the test case 2.
It in one exemplary embodiment, can be second element by the first rubidium marking of target detection use-case, and by the The corresponding all matrix elements arranged of Was Used are labeled as second element;In embodiments of the present invention, which can be " -1 ", certainly in the specific implementation, the second element can be any other numerical value such as " 0 ", " -2 " etc., implement in the present invention It is repeated no more in example.It is the schematic diagram of test case requirement matrix after a kind of label provided in an embodiment of the present invention referring to Fig. 3, As shown in figure 3, since target detection use-case is test case 2, and test case 2 can satisfy demand 1, demand 2, demand N-1 And the test of demand N, therefore the first element corresponding to test case 2 is all marked as " -1 ";Further, Since test case 2 has been able to covering demand 1, demand 2, demand N-1 and demand N, used without additional test Example carry out the demand test, by all column elements corresponding to demand 1, demand 2, demand N-1 and demand N mark be Second element " -1 ".
According to the test case requirement matrix after label, the demand number of test case is updated.In the specific implementation, for side Just implement, the demand number of other test cases in addition to target detection use-case can be updated, alternatively, updating all test cases Demand number.In one exemplary embodiment, pass through the first element of the every row for the test case requirement matrix that adds up, more cenotype Answer the demand number of test case, in this way according to Fig. 3, the demand number of test case 1 is 0+1=1, therefore the demand of test case 1 Number is updated to 1, and the demand number of test case 2 is updated to 0, and the demand number of test case 3 is updated to 2.
Further, it is possible to again circulation execute step S101 to step S102, obtain new target detection use-case, in this way by It is carried out in the testing requirement for the target detection use-case cover-most selected, therefore using selected target detection use-case Follow-up test.
By the description of above-described embodiment as it can be seen that a kind of test method provided in an embodiment of the present invention, according to test case need Matrix is sought, calculates the demand number of each test case, the test case requirement matrix is for describing what test case was covered Testing requirement;When being greater than threshold value there are the demand number of at least one test case, the maximum test case of demand number is selected to make For target detection use-case;According to target detection use-case, the test case requirement matrix is marked, and is used according to the test after label Example requirement matrix, updates the demand number of each test case;Wherein, all target detection use-cases selected are for testing.It is logical Testing requirement matrix is crossed, the test case of cover-most testing requirement is filtered out, can guarantee to use using less test in this way Example cover-most testing requirement is tested, and is prevented retest and test leakage, is effectively increased testing efficiency and essence Degree.
It referring to fig. 4, is the flow diagram of another test method provided in an embodiment of the present invention.As shown in figure 4, this hair The bright determination process for implementing to be illustrated test set:
Step S201:According to test case requirement matrix, the demand number of each test case is calculated, the test case needs Ask matrix for describing the testing requirement that test case is covered.
Step S202:When being greater than threshold value there are the demand number of at least one test case, the maximum survey of demand number is selected Example is tried out as target detection use-case.
Step S203:According to target detection use-case, the test case requirement matrix is marked, and according to the test after label Use-case requirement matrix updates the demand number of each test case.
Step S204:When the demand number of each test case is respectively less than or is equal to threshold value, test set is determined, according to institute State test set test;Wherein, the test set includes all target detection use-cases selected.
Through the foregoing embodiment, test case requirement matrix is completed in label and update the demand number of each test case Afterwards, further judge whether the demand number of each test case is respectively less than or is equal to threshold value, when the demand number of each test case When respectively less than or being equal to threshold value, characterization test use-case has screened completion, in this way, all target detections filtered out can be used Example group is combined into test set, is tested using the test set.
The something in common of the embodiment of the present invention and above-described embodiment, reference can be made to the description of above-described embodiment, no longer superfluous herein It states.
By the description of above embodiment of the method, it is apparent to those skilled in the art that the present invention can Realize by means of software and necessary general hardware platform, naturally it is also possible to by hardware, but in many cases the former It is more preferably embodiment.Based on this understanding, technical solution of the present invention substantially makes tribute to the prior art in other words The part offered can be embodied in the form of software products, which is stored in a storage medium, packet Some instructions are included to use so that a computer equipment (can be personal computer, server or the network equipment etc.) executes All or part of the steps of the method according to each embodiment of the present invention.And storage medium above-mentioned includes:Read-only memory (ROM), the various media that can store program code such as random access memory (RAM), magnetic or disk.
Corresponding with test method embodiment provided by the invention, the present invention also provides a kind of test devices.
It is a kind of structural schematic diagram of test device provided in an embodiment of the present invention, as shown in figure 5, the test referring to Fig. 5 Device includes:
Computing module 11 calculates the demand number of each test case, the test case according to test case requirement matrix Requirement matrix is for describing the testing requirement that test case is covered;
Selecting module 12 selects demand number maximum when being greater than threshold value there are the demand number of at least one test case Test case is as target detection use-case;
Update module 13 marks the test case requirement matrix according to target detection use-case, and according to the survey after label Example requirement matrix on probation, updates the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
In one exemplary embodiment, the computing module 11 is also used to, when the row pair of the test case requirement matrix Test case is answered, the column of the test case requirement matrix correspond to testing requirement, and test case and testing requirement strong correlation When matrix element is the first element, the first element of the every row for the test case requirement matrix that adds up is used as corresponding test The demand number of example.
In one exemplary embodiment, the update module 13 is also used to, and in test case requirement matrix, target is surveyed First rubidium marking of example on probation is second element, and all matrix elements of column corresponding to second element is labeled as second yuan Element.
In one exemplary embodiment, the update module 13 is also used to, and add up the every of the test case requirement matrix The first capable element updates the demand number of corresponding test case.
Test set in order to obtain, in embodiments of the present invention, the test device can also include collection modules, the set Module can be used for test set being determined, according to the survey when the demand number of each test case is respectively less than or is equal to threshold value Examination collection test;Wherein, the test set includes all target detection use-cases selected.
The embodiment of the invention also provides a kind of nonvolatile computer storage media, the computer storage medium storage There are computer executable instructions, which can be performed the test method in above-mentioned any means embodiment.
It is a kind of structural schematic diagram of electronic equipment for executing test method provided in an embodiment of the present invention, such as referring to Fig. 6 Shown in Fig. 6, which includes:
One or more processors 610 and memory 620, in Fig. 6 by taking a processor 610 as an example.
Execute test method equipment can also include:Input unit 630 and output device 640.
Processor 610, memory 620, input unit 630 and output device 640 can pass through bus or other modes It connects, in Fig. 6 for being connected by bus.
Memory 620 is used as a kind of non-volatile computer readable storage medium storing program for executing, can be used for storing non-volatile software journey Sequence, non-volatile computer executable program and module, as the corresponding program instruction of test method in the embodiment of the present invention/ Module (for example, attached computing module shown in fig. 5 11, selecting module 12 and update module 13).Processor 610 passes through operation storage Non-volatile software program, instruction and module in memory 620, thereby executing server various function application and The test method of above method embodiment is realized in data processing.
Memory 620 may include storing program area and storage data area, wherein storing program area can store operation system Application program required for system, at least one function;Storage data area, which can be stored, uses created number according to test device According to etc..In addition, memory 620 may include high-speed random access memory, it can also include nonvolatile memory, such as extremely A few disk memory, flush memory device or other non-volatile solid state memory parts.In some embodiments, memory 620 it is optional include the memory remotely located relative to processor 610, these remote memories can pass through network connection to surveying Trial assembly is set.The example of above-mentioned network includes but is not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
Input unit 630 can receive the number or character information of input, and generate with the user setting of test device with And the related key signals input of function control.Output device 640 may include that display screen etc. shows equipment.
One or more of modules are stored in the memory 620, when by one or more of processors When 610 execution, the test method in above-mentioned any means embodiment is executed.
Method provided by the embodiment of the present invention can be performed in the said goods, has the corresponding functional module of execution method and has Beneficial effect.The not technical detail of detailed description in the present embodiment, reference can be made to method provided by the embodiment of the present invention.
The electronic equipment of the embodiment of the present invention exists in a variety of forms, including but not limited to:
(1) mobile communication equipment:The characteristics of this kind of equipment is that have mobile communication function, and to provide speech, data Communication is main target.This Terminal Type includes:Smart phone (such as iPhone), multimedia handset, functional mobile phone and low Hold mobile phone etc..
(2) super mobile personal computer equipment:This kind of equipment belongs to the scope of personal computer, there is calculating and processing function Can, generally also have mobile Internet access characteristic.This Terminal Type includes:PDA, MID and UMPC equipment etc., such as iPad.
(3) portable entertainment device:This kind of equipment can show and play multimedia content.Such equipment includes:Audio, Video player (such as iPod), handheld device, e-book and intelligent toy and portable car-mounted navigation equipment.
(4) server:There is provided the equipment of the service of calculating, the composition of server includes that processor, hard disk, memory, system are total Line etc., server is similar with general computer architecture, but due to needing to provide highly reliable service, in processing energy Power, stability, reliability, safety, scalability, manageability etc. are more demanding.
(5) other electronic devices with data interaction function.
The apparatus embodiments described above are merely exemplary, wherein described, unit can as illustrated by the separation member It is physically separated with being or may not be, component shown as a unit may or may not be physics list Member, it can it is in one place, or may be distributed over multiple network units.It can be selected according to the actual needs In some or all of the modules achieve the purpose of the solution of this embodiment
All the embodiments in this specification are described in a progressive manner, same and similar portion between each embodiment Dividing may refer to each other, and each embodiment focuses on the differences from other embodiments.Especially for device or For system embodiment, since it is substantially similar to the method embodiment, so describing fairly simple, related place is referring to method The part of embodiment illustrates.Apparatus and system embodiment described above is only schematical, wherein the conduct The unit of separate part description may or may not be physically separated, component shown as a unit can be or Person may not be physical unit, it can and it is in one place, or may be distributed over multiple network units.It can root According to actual need that some or all of the modules therein is selected to achieve the purpose of the solution of this embodiment.Ordinary skill Personnel can understand and implement without creative efforts.
It should be noted that, in this document, the relational terms of such as " first " and " second " or the like are used merely to one A entity or operation with another entity or operate distinguish, without necessarily requiring or implying these entities or operation it Between there are any actual relationship or orders.Moreover, the terms "include", "comprise" or its any other variant are intended to Cover non-exclusive inclusion, so that the process, method, article or equipment for including a series of elements not only includes those Element, but also including other elements that are not explicitly listed, or further include for this process, method, article or setting Standby intrinsic element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that There is also other identical elements in the process, method, article or apparatus that includes the element.
The above is only a specific embodiment of the invention, is made skilled artisans appreciate that or realizing this hair It is bright.Various modifications to these embodiments will be apparent to one skilled in the art, as defined herein General Principle can be realized in other embodiments without departing from the spirit or scope of the present invention.Therefore, of the invention It is not intended to be limited to the embodiments shown herein, and is to fit to and the principles and novel features disclosed herein phase one The widest scope of cause.

Claims (10)

1. a kind of test method, which is characterized in that include the following steps:
According to test case requirement matrix, the demand number of each test case is calculated, the test case requirement matrix is for retouching State the testing requirement that test case is covered;
When being greater than threshold value there are the demand number of at least one test case, select the maximum test case of demand number as target Test case;
According to target detection use-case, the test case requirement matrix is marked, and according to the test case requirement matrix after label, Update the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
2. test method according to claim 1, which is characterized in that it is described according to test case requirement matrix, it calculates each The demand number of a test case includes:
When the corresponding test case of the row of the test case requirement matrix, the corresponding test of the column of the test case requirement matrix is needed It asks, and when the matrix element of test case and testing requirement strong correlation is the first element, add up the test case requirement matrix Every row the first element, the demand number as corresponding test case.
3. test method according to claim 2, which is characterized in that according to the target detection use-case, mark the survey Example requirement matrix on probation, including:
It is second element by the first rubidium marking of target detection use-case, and by second element in test case requirement matrix All matrix elements of corresponding column are labeled as second element.
4. test method according to claim 3, which is characterized in that the test case demand square according to after label Battle array, updates the demand number of each test case, including:
Add up the test case requirement matrix every row the first element, update the demand number of corresponding test case.
5. test method according to claim 1, which is characterized in that further include:
When the demand number of each test case is respectively less than or is equal to threshold value, test set is determined, to test according to the test set; Wherein, the test set includes all target detection use-cases selected.
6. a kind of test device, which is characterized in that including:
Computing module calculates the demand number of each test case, the test case demand square according to test case requirement matrix Battle array is for describing the testing requirement that test case is covered;
Selecting module selects the maximum test of demand number to use when being greater than threshold value there are the demand number of at least one test case Example is used as target detection use-case;
Update module marks the test case requirement matrix according to target detection use-case, and according to the test case after label Requirement matrix updates the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
7. test device according to claim 6, which is characterized in that the computing module is also used to,
When the corresponding test case of the row of the test case requirement matrix, the corresponding test of the column of the test case requirement matrix is needed It asks, and when the matrix element of test case and testing requirement strong correlation is the first element, add up the test case requirement matrix Every row the first element, the demand number as corresponding test case.
8. test device according to claim 6, which is characterized in that the update module is also used to,
It is second element by the first rubidium marking of target detection use-case, and by second element in test case requirement matrix All matrix elements of corresponding column are labeled as second element.
9. according to the described in any item test devices of claim 6 to 8, which is characterized in that the test device further includes collection molding Block is used for,
When the demand number of each test case is respectively less than or is equal to threshold value, test set is determined, to test according to the test set; Wherein, the test set includes all target detection use-cases selected.
10. a kind of electronic equipment, which is characterized in that the electronic equipment includes at least one processor;And
The memory being connect at least one described processor communication;Wherein,
The memory is stored with the instruction that can be executed by one processor, and described instruction is by least one described processor It executes, so that at least one described processor can:
According to test case requirement matrix, the demand number of each test case is calculated, the test case requirement matrix is for retouching State the testing requirement that test case is covered;
When being greater than threshold value there are the demand number of at least one test case, select the maximum test case of demand number as target Test case;
According to target detection use-case, the test case requirement matrix is marked, and according to the test case requirement matrix after label, Update the demand number of each test case;
Wherein, all target detection use-cases selected are for testing.
CN201810288883.9A 2018-04-03 2018-04-03 A kind of test method, device and electronic equipment Pending CN108920353A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810288883.9A CN108920353A (en) 2018-04-03 2018-04-03 A kind of test method, device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810288883.9A CN108920353A (en) 2018-04-03 2018-04-03 A kind of test method, device and electronic equipment

Publications (1)

Publication Number Publication Date
CN108920353A true CN108920353A (en) 2018-11-30

Family

ID=64402971

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810288883.9A Pending CN108920353A (en) 2018-04-03 2018-04-03 A kind of test method, device and electronic equipment

Country Status (1)

Country Link
CN (1) CN108920353A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110083527A (en) * 2019-03-18 2019-08-02 平安普惠企业管理有限公司 A kind of generation method and device, electronic equipment of test case
CN111309608A (en) * 2020-02-13 2020-06-19 咪咕音乐有限公司 Test case selection method and device, electronic equipment and readable storage medium
CN114996076A (en) * 2022-07-01 2022-09-02 北京联盛德微电子有限责任公司 Traversal type use case verification method and system for chip simulation and electronic equipment
CN116501653A (en) * 2023-06-30 2023-07-28 卡斯柯信号(北京)有限公司 Software regression testing method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040068702A1 (en) * 2002-10-08 2004-04-08 Parker Kenneth P. Methods for predicting board test coverage
CN103810104A (en) * 2014-03-04 2014-05-21 中国人民解放军63863部队 Method and system for optimizing software test case
CN104391790A (en) * 2014-11-21 2015-03-04 浪潮电子信息产业股份有限公司 Automatic test case selection method based on greedy algorithm

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040068702A1 (en) * 2002-10-08 2004-04-08 Parker Kenneth P. Methods for predicting board test coverage
CN103810104A (en) * 2014-03-04 2014-05-21 中国人民解放军63863部队 Method and system for optimizing software test case
CN104391790A (en) * 2014-11-21 2015-03-04 浪潮电子信息产业股份有限公司 Automatic test case selection method based on greedy algorithm

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110083527A (en) * 2019-03-18 2019-08-02 平安普惠企业管理有限公司 A kind of generation method and device, electronic equipment of test case
CN111309608A (en) * 2020-02-13 2020-06-19 咪咕音乐有限公司 Test case selection method and device, electronic equipment and readable storage medium
CN111309608B (en) * 2020-02-13 2023-09-05 咪咕音乐有限公司 Test case selection method and device, electronic equipment and readable storage medium
CN114996076A (en) * 2022-07-01 2022-09-02 北京联盛德微电子有限责任公司 Traversal type use case verification method and system for chip simulation and electronic equipment
CN116501653A (en) * 2023-06-30 2023-07-28 卡斯柯信号(北京)有限公司 Software regression testing method and device
CN116501653B (en) * 2023-06-30 2023-10-03 卡斯柯信号(北京)有限公司 Software regression testing method and device

Similar Documents

Publication Publication Date Title
CN108920353A (en) A kind of test method, device and electronic equipment
CN104217717B (en) Build the method and device of language model
CN110366734A (en) Optimization neural network framework
CN106294120A (en) The test method of code, equipment and computer program
CN103155428A (en) Apparatus and method for adaptive gesture recognition in portable terminal
CN107678799A (en) Application program management-control method, device, storage medium and electronic equipment
CN105074495A (en) Adaptive assistance data for tiered service and efficiency in indoor positioning
CN109840205A (en) Applied program testing method, device, readable storage medium storing program for executing and terminal device
CN109214674B (en) Customer service system management method, customer service system and electronic equipment
CN104133765B (en) The test case sending method of network activity and test case server
CN104049217A (en) Detection method and device for use time of remaining capacity of battery
CN107370877A (en) Method for pushing, device, storage medium and the electronic equipment of application program
CN110489641A (en) A kind of information recommendation data processing method and device
CN107133038A (en) A kind of application program changes the method and its device of skin
CN110046088A (en) A kind of interface test method, device and equipment
CN106155699A (en) The management method of a kind of background process and mobile terminal
CN109656815A (en) There are test statement write method, device, medium and the electronic equipment of configuration file
CN106250182A (en) File processing method and device and electronic equipment
CN107943685A (en) A kind of traverse path generation method, device, server and storage medium
CN102929622A (en) Method and system for categorizing applications in mobile terminal, and mobile terminal
CN106021101A (en) Method and device for testing mobile terminal
CN103885767B (en) System and method used for geographical area correlated websites
CN107402720A (en) A kind of processing method of hard disk, device and terminal
CN115081613A (en) Method and device for generating deep learning model, electronic equipment and storage medium
CN107943571A (en) Background application management-control method, device, storage medium and electronic equipment

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20181130

RJ01 Rejection of invention patent application after publication