CN111538673B - Processing method, device, equipment and storage medium based on test case - Google Patents

Processing method, device, equipment and storage medium based on test case Download PDF

Info

Publication number
CN111538673B
CN111538673B CN202010499707.7A CN202010499707A CN111538673B CN 111538673 B CN111538673 B CN 111538673B CN 202010499707 A CN202010499707 A CN 202010499707A CN 111538673 B CN111538673 B CN 111538673B
Authority
CN
China
Prior art keywords
case
statistics
leaf node
test
condition
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.)
Active
Application number
CN202010499707.7A
Other languages
Chinese (zh)
Other versions
CN111538673A (en
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.)
China United Network Communications Group Co Ltd
Unicompay Co Ltd
Original Assignee
China United Network Communications Group Co Ltd
Unicompay 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 China United Network Communications Group Co Ltd, Unicompay Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN202010499707.7A priority Critical patent/CN111538673B/en
Publication of CN111538673A publication Critical patent/CN111538673A/en
Application granted granted Critical
Publication of CN111538673B publication Critical patent/CN111538673B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

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
    • 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/3688Test management for test execution, e.g. scheduling of test suites
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Abstract

The application provides a processing method, a device, equipment and a storage medium based on test cases, wherein the method comprises the following steps: receiving a current operation input by a user, wherein the current operation comprises the steps that the user inputs a case statistics condition and clicks a preset button control after inputting the case statistics condition; determining a case statistical result corresponding to the case statistical condition according to the current operation, wherein the case statistical result is used for indicating a result of statistics on all test cases corresponding to the case statistical condition; and displaying the case statistics results corresponding to the case statistics conditions. The complexity of the statistics process is reduced, the statistics is more flexible, and the efficiency of acquiring the statistics result of the required use case is improved.

Description

Processing method, device, equipment and storage medium based on test case
Technical Field
The present disclosure relates to the field of testing technologies, and in particular, to a processing method, device, equipment, and storage medium based on a test case.
Background
In recent years, writing test cases based on mind map has become the first choice for testers. After a set of test cases written based on the mind map is obtained, the set of test cases can be used for testing related software products, and execution results of each test case, such as pass, fail and the like, are obtained. Currently, in order to facilitate a tester to know the execution condition of a test case, statistics needs to be performed on the execution result of the test case.
In the prior art, the execution result of the test case is counted in a manual mode. Specifically, the tester needs to search and manually record the execution result of each test case, and then the tester performs manual statistics according to the recorded content to obtain the required case statistics result.
However, in the prior art, the number of a set of test cases written based on the mind map is generally large, so that if statistics is performed according to the existing mode, the statistics process is complicated, a lot of time is spent, and the statistics efficiency is low.
Disclosure of Invention
The processing method, the processing device, the processing equipment and the storage medium based on the test cases reduce the complexity of the statistics process, enable the statistics to be more flexible, and improve the efficiency of acquiring the statistics results of the required cases.
In a first aspect, the present application provides a test case-based processing method, where the method includes:
receiving a current operation input by a user, wherein the current operation comprises the steps that the user inputs a case statistics condition and clicks a preset button control after inputting the case statistics condition;
determining a case statistical result corresponding to the case statistical condition according to the current operation, wherein the case statistical result is used for indicating a result of statistics on all test cases corresponding to the case statistical condition;
and displaying the use case statistical result corresponding to the use case statistical condition.
Further, before the receiving the current operation of the user input, the method further comprises:
acquiring a mind map test case file input by a user, wherein the mind map test case file comprises a plurality of test cases, each test case in the plurality of test cases has an icon identification, and the icon identification is used for indicating an execution result of the test case;
the determining the case statistics result corresponding to the case statistics condition comprises the following steps:
and determining the case statistical result based on icon identifications of all the test cases corresponding to the case statistical conditions in the mind-induced graph test case file.
Further, the case statistics conditions include a first statistics condition, the preset button control includes a first button control, and the case statistics result includes the number of different execution results of all test cases corresponding to the first statistics condition.
Further, each test case in the plurality of test cases corresponds to a link, at least one level of non-leaf nodes and one leaf node are sequentially arranged on the link, the initial positions of all the links correspond to the same non-leaf node, and the leaf node is provided with an icon identifier corresponding to the test case;
after the thinking guide diagram test case file input by the user is obtained, the method further comprises the following steps:
determining a statistical set corresponding to each non-leaf node based on icon identifications on all the leaf nodes contained in each non-leaf node, wherein the statistical set comprises the number of different execution results corresponding to all the leaf nodes contained in the non-leaf node;
in the test case file based on the mind map, the icon identifiers of all test cases corresponding to the case statistics conditions are included, and the determining the case statistics result includes:
and determining the non-leaf node indicated by the first statistical condition, and determining a statistical set corresponding to the indicated non-leaf node as the use case statistical result.
Further, the case statistics conditions include a second statistics condition, the preset button control includes a second button control, and the case statistics result includes names of all test cases corresponding to the second statistics condition.
Further, the second statistical condition includes any one or more of the following: execution pass case name, execution fail case name, execution block case name, no applicable case name, no execution case name.
In a second aspect, the present application provides a processing device based on a test case, where the device includes a receiving unit, a determining unit, and a display unit, where,
the receiving unit is used for receiving the current operation input by the user, wherein the current operation comprises the user input of a case statistics condition and the user clicking a preset button control after the user input of the case statistics condition;
the determining unit is configured to determine, according to the current operation, a case statistics result corresponding to the case statistics condition, where the case statistics result is used to indicate a result of statistics for all test cases corresponding to the case statistics condition;
the display unit is used for displaying the use case statistical result corresponding to the use case statistical condition.
Further, the apparatus further comprises: an acquisition unit;
the acquisition unit is used for acquiring a mind map test case file input by a user before the receiving unit receives the current operation, wherein the mind map test case file comprises a plurality of test cases, each test case in the plurality of test cases is provided with an icon identification, and the icon identification is used for indicating an execution result of the test case;
the determining unit is specifically configured to determine the case statistics result based on icon identifiers of all test cases corresponding to the case statistics conditions in the mind map test case file.
Further, the case statistics conditions include a first statistics condition, the preset button control includes a first button control, and the case statistics result includes the number of different execution results of all test cases corresponding to the first statistics condition.
Further, each test case in the plurality of test cases corresponds to a link, at least one level of non-leaf nodes and one leaf node are sequentially arranged on the link, the initial positions of all the links correspond to the same non-leaf node, and the leaf node is provided with an icon identifier corresponding to the test case;
further, the determining unit is further configured to determine, before the obtaining unit obtains the mind map test case file, a statistics set corresponding to each non-leaf node based on the icon identifiers on all the leaf nodes included in each non-leaf node, where the statistics set includes the number of different execution results corresponding to all the leaf nodes included in the non-leaf node;
the determining unit is specifically configured to determine a non-leaf node indicated by the first statistics condition, and determine a statistics set corresponding to the indicated non-leaf node as the use case statistics result.
Further, the case statistics conditions include a second statistics condition, the preset button control includes a second button control, and the case statistics result includes names of all test cases corresponding to the second statistics condition.
Further, the second statistical condition includes any one or more of the following: execution pass case name, execution fail case name, execution block case name, no applicable case name, no execution case name.
In a third aspect, the present application provides a processing device based on a test case, including: a memory and a processor;
the memory is used for storing a computer program;
wherein the processor executes the computer program in the memory to implement any of the methods of the first aspect.
In a fourth aspect, the present application provides a computer-readable storage medium having stored therein computer-executable instructions which, when executed by a processor, are adapted to carry out any of the methods of the first aspect.
According to the processing method, the device, the equipment and the storage medium based on the test cases, through receiving the current operation input by the user, wherein the current operation comprises the process of inputting the case statistics conditions by the user and clicking the preset button control after the user inputs the case statistics conditions, then the case statistics results corresponding to the case statistics conditions can be determined according to the current operation, the case statistics results corresponding to the case statistics conditions are displayed to the user, namely, when the user needs to conduct statistics, the user only needs to input the case statistics conditions required to be counted, then clicking the preset button assembly to obtain the corresponding case statistics results, the process of manually searching, manually recording and manually counting by the user is avoided, the complexity of the statistics process is reduced, the efficiency of obtaining the required case statistics results is improved, and the statistics mode is more flexible.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure.
FIG. 1 is a schematic diagram I of an interface interaction provided herein;
FIG. 2 is a second schematic diagram of an interface interaction provided herein;
FIG. 3 is a flowchart of a test case-based processing method according to an embodiment of the present application;
FIG. 4 is a flowchart of a test case-based processing method according to a second embodiment of the present application;
FIG. 5 is a schematic content diagram of a test case file of a mind map according to a second embodiment of the present application;
fig. 6 is a schematic structural diagram of a processing device based on a test case according to a third embodiment of the present application;
fig. 7 is a schematic structural diagram of a processing device based on a test case according to a fourth embodiment of the present application;
fig. 8 is a schematic structural diagram of a processing device based on a test case according to a fifth embodiment of the present application.
Specific embodiments of the present disclosure have been shown by way of the above drawings and will be described in more detail below. These drawings and the written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the disclosed concepts to those skilled in the art by reference to specific embodiments.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure as detailed in the accompanying claims.
In the prior art, when a tester needs to count the execution results of test cases based on a thinking guide chart, the tester must obtain the required case counting result through the processes of manual searching, manual recording and manual counting, so that the efficiency of obtaining the required case counting result is extremely low.
Based on the above, the present application provides a processing method, device, equipment and storage medium based on a test case, by receiving a current operation input by a user, where the current operation includes that the user inputs a case statistics condition, and the user clicks a preset button control after inputting the case statistics condition, according to the current operation, a case statistics result corresponding to the case statistics condition can be displayed to the user, that is, the user only needs to input a required case statistics condition, and then clicks the preset button control, that is, the user only needs to operate two steps, so as to obtain the required case statistics result. When the case statistics conditions comprise first statistics conditions, the preset button control comprises a first button control; and when the case statistics conditions comprise second statistics conditions, the preset button control comprises a second button control. Specifically, fig. 1 is a schematic diagram of an interface interaction provided in the present application, and fig. 2 is a schematic diagram of an interface interaction provided in the present application. As shown in fig. 1, a user may input a first statistics condition in two input boxes corresponding to the statistics execution result shown in fig. 1, and then click on a first button control, i.e., a "statistics number" button control, so as to display a case statistics result corresponding to the first statistics condition, where the case statistics result includes the number of different execution results of the test cases corresponding to the first statistics condition. As shown in fig. 2, the user may input the second statistical condition in the input box corresponding to the view execution condition shown in fig. 2, and then click on the second button control, that is, the "view" button control, so that the case statistical result corresponding to the second statistical condition may be displayed, where the case statistical result includes names of all test cases corresponding to the second statistical condition. The processing method, device, equipment and storage medium based on the test case provided by the application are described in detail below.
Fig. 3 is a flow chart of a processing method based on a test case according to an embodiment of the present application, and as shown in fig. 3, the method includes:
step 301: and receiving the current operation input by the user, wherein the current operation comprises the steps of inputting the case statistics condition by the user and clicking a preset button control by the user after inputting the case statistics condition.
In this embodiment, the current operation input by the user is received, where the user may specifically refer to a tester or the like, which is not limited in this case. The current operation includes the user inputting the case statistics condition, specifically, the user may input the corresponding case statistics condition according to the actual requirement, for example, the user currently wants to count the execution result of all the test cases, and the case statistics condition input by the user may be "count all". The current operation further comprises clicking a preset button control by the user after inputting the case statistics condition, namely, after receiving the operation of inputting the case statistics condition by the user and receiving the operation of clicking the preset button control by the user, determining the case statistics result corresponding to the received case statistics condition. That is, for the user, the user only needs to input a required case statistics condition, and click a preset button control after inputting the case statistics condition.
Step 302: and determining case statistics results corresponding to the case statistics conditions according to the current operation, wherein the case statistics results are used for indicating the results of statistics on all test cases corresponding to the case statistics conditions.
In this embodiment, after receiving an operation of inputting a case statistics condition by a user and an operation of clicking a preset button control after receiving the user input the case statistics condition, a case statistics result corresponding to the currently received case statistics condition is automatically determined, where the case statistics result is used to indicate a result of statistics on all test cases corresponding to the case statistics condition. If the case statistics condition is "statistics all", automatically determining the result of statistics for all the test cases after receiving the operation of inputting "statistics all" by the user and the operation of clicking the preset button control by the user, and displaying the result of statistics for all the test cases to the user.
For example, there are 8 test cases in total, where the execution result corresponding to test case 1 is execution pass, the execution result corresponding to test case 2 is execution fail, the execution result corresponding to test case 3 is execution pass, the execution result corresponding to test case 4 is execution block, the execution result corresponding to test case 5 is inapplicable, the execution result corresponding to test case 6 is non-execution, the execution result corresponding to test case 7 is execution fail, the execution result corresponding to test case 8 is execution block, and assuming that the user-input case statistics condition is "statistics all", determining the case statistics result corresponding to the case statistics condition may include: "test case total: 8, 8; by: 2; failure: 2; blocking: 2; the method is not applicable: 1, a step of; the method is not performed: 1".
Step 303: and displaying the case statistics results corresponding to the case statistics conditions.
In this embodiment, after determining the case statistics corresponding to the case statistics conditions currently received, the case statistics corresponding to the case statistics conditions may be displayed. The display format of the use case statistics may be configured in advance, for example, the display format in step 302 is displayed, or the number corresponding to different execution results is displayed vertically, which is not limited in this case. The above is only illustrated with 8 test cases.
The embodiment provides a processing method based on test cases, which is characterized in that a current operation input by a user is received, wherein the current operation comprises the steps of inputting a case statistics condition by the user and clicking a preset button control by the user after inputting the case statistics condition, then the case statistics result corresponding to the case statistics condition can be determined according to the current operation, the case statistics result corresponding to the case statistics condition is displayed to the user, namely, when the user needs to perform statistics, the user only needs to input the case statistics condition of required statistics, then the corresponding case statistics result can be obtained by clicking the preset button assembly, the processes of manually searching, manually recording and manually counting by the user are avoided, the complexity of the statistics process is reduced, the efficiency of obtaining the required case statistics result is improved, and the statistics mode is more flexible.
Fig. 4 is a flow chart of a processing method based on a test case according to a second embodiment of the present application, as shown in fig. 4, where the method includes:
step 401: and acquiring a mind map test case file input by a user, wherein the mind map test case file comprises a plurality of test cases, and each test case in the plurality of test cases has an icon identification which is used for indicating an execution result of the test case.
In this embodiment, to display the case statistics result corresponding to the case statistics condition, the mind map test case file input by the user may be acquired first. In one implementation, as shown in FIG. 1, a user may click on the "select case file" button control of FIG. 1, based on which a storage path "E: \\test.xmind" of the mind map test case file is entered, thereby obtaining the mind map test case file based on the storage path. The thinking guide graph test case file comprises a plurality of test cases, each test case in the plurality of test cases is provided with an icon identification, the icon identification is used for indicating the execution result of the test case, wherein the execution result of the test case is different, the corresponding icon identification is also different, if the execution result is that the execution passes, one icon identification is corresponding to the other icon identification, and if the execution result is that the execution fails, the icon identification is null for the test case which is not executed in the plurality of test cases, namely the test case which is not executed may not correspond to the icon identification. The mind map test case file may be obtained based on a preset execution specification, where the execution specification includes: aiming at the executed test cases, marking the corresponding test cases by using the defined icon marks; for the test case which is not executed, marking is not carried out, namely the icon mark corresponding to the test case which is not executed is empty.
Specifically, the thinking guide graph test case file comprises a plurality of test cases, each test case corresponds to a link, at least one level of non-leaf nodes and one leaf node are sequentially arranged on the link, the initial positions of all the links correspond to the same non-leaf node, and the leaf nodes are provided with icon identifiers corresponding to the test cases. In other words, the starting position of the link is the root node, the ending position of the link is the leaf node, and the starting positions of all links correspond to the same non-leaf node, that is, all links correspond to the same root node.
For example, fig. 5 is a schematic content diagram of a mind map test case file provided in the second embodiment of the present application, and as shown in fig. 5, the mind map test case file includes 5 test cases a-B-D, A-B-E, A-C-F-H, A-C-F-I, A-C-G-J, where a is a root node (i.e., a first-level non-leaf node), D, E, H, I, J is a leaf node, B, C is a second-level non-leaf node (may also be referred to as a first child node), F, G is a third-level non-leaf node (may also be referred to as a second child node), and a complete link from the root node to the leaf node is taken as a test case. D. The four leaf nodes E, H, I are respectively provided with different icon identifications, wherein the execution result indicated by the icon identifications on D is an execution failure, the execution result indicated by the icon identifications on E is an execution pass, the execution result indicated by the icon identifications on H is an execution block, the execution result indicated by the icon identifications on I is inapplicable, the icon identifications on J are blank, and the execution result indicated by the icon identifications on J is that the test case has not been executed.
In this embodiment, after the mind map test case file input by the user is obtained, the mind map test case file may be first converted into an XML format file, and then, to improve the efficiency of obtaining the statistics result of the required case by the user, the method may further include: and determining a statistical set corresponding to each non-leaf node based on the icon identifications on all the leaf nodes contained in each non-leaf node, wherein the statistical set comprises the number of different execution results corresponding to all the leaf nodes contained in the non-leaf node.
Taking the schematic content of the mind map test case file shown in fig. 5 as an example, the content includes 5 non-leaf nodes A, B, C, F, G. Taking the non-leaf node F as an example, the non-leaf node F contains two leaf nodes of H and I, the determined statistics set includes "blocking" for the non-leaf node F: 1, a step of; the method is not applicable: 1". Taking the non-leaf node C as an example, the non-leaf node C includes H, I, J three leaf nodes, and the determined statistics set includes "blocking" for the non-leaf node C: 1, a step of; the method is not applicable: 1, a step of; the method is not performed: 1". The statistics set for other non-leaf nodes can be analogized and are not repeated here.
In one implementation manner, in order to facilitate statistics of a statistics set corresponding to each non-leaf node, all leaf nodes can be traversed first, then for each leaf node, which type of identifier exists in the current leaf node is judged, then 1 is added to the number of such icon identifiers recorded in all father nodes of the current leaf node, and the result is stored in the hashmap, all keys of the hashmap obtained after the traversal are names of the non-leaf nodes in the mind map test case file, the corresponding value is the statistics set, namely the statistics set stores the number of different icon identifiers contained in all leaf nodes contained in the corresponding non-leaf node below for list types. For example, traversing finds D, E, H, I, J a total of 5 leaf nodes, taking traversing the first leaf node D as an example, if the execution result represented by the icon identifier on the leaf node D is that the execution fails, then all parent nodes of the leaf node D include non-leaf nodes B and a, then the number of such icon identifiers recorded on the non-leaf node B is added by 1 to obtain 1, and the number of such icon identifiers recorded on the non-leaf node a is added by 1 to obtain 1; taking traversing the second leaf node E as an example, if all the father nodes of the leaf node E comprise non-leaf nodes B and A, adding 1 to the number of the non-leaf node B record such icon marks (adding 1 again on the basis of the previous 1) to obtain 2, adding 1 to the number of the non-leaf node A record such icon marks to obtain 2, and so on to obtain a statistical set corresponding to each non-leaf node.
In addition, the key value in the hashmap is marked with a prefix according to the position of the non-leaf node, so that a user can count an execution result according to different dimensions, for example, the key value of the root node marks the prefix as a root, namely a root-key; the key value of the first child node marks the prefix as first, namely first-key; the key value of the second child node is marked with a prefix second, namely second-key, and the key values of other child nodes are marked with more, namely more-key. Meanwhile, based on the prefix of the key mark, a corresponding statistical set can be quickly found, and then a corresponding use case statistical result is displayed to a user.
Step 402: and receiving the current operation input by the user, wherein the current operation comprises the steps of inputting the case statistics condition by the user and clicking a preset button control by the user after inputting the case statistics condition.
In this embodiment, the case statistics condition includes a first statistics condition, and the preset button control includes a first button control. As shown in fig. 1 or fig. 2, the first button control is a "statistics number" button control, and the user may input a first statistics condition in two input boxes corresponding to the "statistics execution result" in fig. 1, for example, the user wants to count the execution result of all test cases, then the user may select "statistics all" in the first input box corresponding to the "statistics execution result" (the first input box from left to right), and for the case where the statistics condition of the case is "statistics all", the second input box corresponding to the "statistics execution result" may be empty, and then the user may obtain statistics of the execution result of all test cases by clicking the "statistics number" button control, and using the content of the mind map test case file shown in fig. 5 as an example, for example, the lower half of the interface shown in fig. 1 shows the application case statistics result corresponding to all test cases to the user.
In this embodiment, in addition to counting the execution results of all test cases, statistical queries of different dimensions may be performed. For example, the user may select to input the first sub-node in the first input box corresponding to the "statistics execution result", taking the content of the mind-map test case file shown in fig. 5 as an example, and include B, C two first sub-nodes altogether, assuming that the name of the first sub-node B is login and the name of the first sub-node C is registration, if the user needs to count the execution result of the test case corresponding to the first sub-node B currently, the user needs to input the name of the first sub-node B (i.e. input login) in the second input box corresponding to the "statistics execution result", so that after clicking the "statistics query" button control, the user will display the application case statistics result corresponding to the first sub-node B. The statistical query for the second child node may be according to the statistical query for the first child node B, which is not described herein.
In addition, query statistics of the custom child nodes (namely, the custom non-leaf nodes) can be supported, namely, a user can input 'custom statistics according to the child nodes' in a first input box corresponding to 'statistics executing results', and then the user can input corresponding names in a second input box corresponding to 'statistics executing results'.
In this embodiment, the case statistics conditions include a second statistics condition, and the preset button control includes a second button control. As shown in fig. 1 or fig. 2, the second button control is a "view" button control, and the user may input a second statistical condition in an input box corresponding to the "view execution condition" in fig. 1 or fig. 2, where the second statistical condition includes any one or more of the following: execution pass case name, execution fail case name, execution block case name, no applicable case name, no execution case name. The user inputs the second statistical condition as the name of the passing test case, then clicks the "view" button control, so that the names of all the test cases passing through the execution can be obtained, the content of the mind-map test case file shown in fig. 5 is taken as an example, for example, the lower half part of the interface shown in fig. 2 shows that all the test cases are displayed in the user, when the results of the execution are the names of the test cases passing through the execution, the names corresponding to the leaf nodes of the test cases can be displayed, and the names of the test cases A-B-E passing through the execution are displayed as the names of the leaf nodes E (for example, the names of E are account passwords for login).
Step 403: according to the current operation, determining a case statistics result based on icon identifications of all test cases corresponding to case statistics conditions in the mind-induced graph test case file, wherein the case statistics result is used for indicating a result of statistics on all test cases corresponding to the case statistics conditions.
In this embodiment, after receiving the current operation input by the user, the case statistics result may be determined based on the icon identifiers of all the test cases corresponding to the case statistics conditions in the mind map test case file. Illustratively, if the case statistics conditions include a first statistics condition, where the first statistics condition is "statistics complete", and the content of the mind map test case file shown in fig. 5 is taken as an example, the case statistics result may be determined based on icon identifications of the 5 test cases, that is, icon identifications on leaf nodes of the 5 test cases. Taking the content of the mind map test case file shown in fig. 5 as an example, the corresponding case statistics result can be determined based on the icon identifications of 2 test cases (i.e., test cases a-B-D, A-B-E) corresponding to the first child node B, i.e., the icon identifications on leaf nodes of the 2 test cases, where the case statistics conditions include a first statistics condition, the first statistics condition is "statistics first child node" and "log-in" (i.e., the name of the first child node B). For further example, if the case statistics conditions include a second statistics condition, where the second statistics condition is "execute passing case name", and the content of the mind-map test case file shown in fig. 5 is taken as an example, then based on the icon identifications of 1 test case (i.e. a-B-E) corresponding to the "execute passing case name", that is, the icon identifications on the leaf nodes of the 1 test case, a corresponding case statistics result is determined, where the case statistics result is the name of the leaf node E.
In this embodiment, in order to more quickly display the use case statistics result to the user, when the use case statistics condition includes the first statistics condition and the preset button control includes the first button control, step 403 may specifically include: and determining the non-leaf node indicated by the first statistical condition, and determining a statistical set corresponding to the indicated non-leaf node as a use case statistical result.
Taking the content of the mind map test case file shown in fig. 5 as an example, the first statistics condition input by the user includes "statistics first child node" and "login" (i.e., the name of the first child node B), the non-leaf node indicated by the first statistics condition may be determined to be B, since the statistics set corresponding to each non-leaf node has been determined before, because when the indicated non-leaf node is determined to be B, the statistics set corresponding to B may be directly determined to be the current case statistics result.
Step 404: and displaying the case statistics results corresponding to the case statistics conditions.
In this embodiment, after determining the case statistics corresponding to the case statistics conditions, the case statistics may be displayed. As shown in fig. 1, the lower half of the interface shown in fig. 1 shows the use case statistics corresponding to the first statistics condition "statistics all". The lower half of the interface shown in fig. 2 shows the use case statistic result corresponding to the second statistic condition "execution pass use case name". In fig. 1 and fig. 2, the case statistics result is shown to the user in the lower half area of the current query page, and in addition, a page may be popped up again, which is dedicated to displaying the case statistics result corresponding to the case statistics condition.
According to the embodiment, through receiving the first statistical condition input by the user, the quick query statistics of the execution results of the test cases can be realized, and meanwhile, the statistics of the execution results under different dimensions can be realized; in addition, by receiving the second statistical condition input by the user, the execution condition of the test case can be checked, and the statistical flexibility is improved.
Fig. 6 is a schematic structural diagram of a processing device based on a test case according to a third embodiment of the present application, where, as shown in fig. 6, the device includes: a receiving unit 601, a determining unit 602 and a display unit 603, wherein,
a receiving unit 601, configured to receive a current operation input by a user, where the current operation includes the user inputting a case statistics condition, and the user clicking a preset button control after inputting the case statistics condition;
a determining unit 602, configured to determine, according to a current operation, a case statistics result corresponding to a case statistics condition, where the case statistics result is used to indicate a result of statistics for all test cases corresponding to the case statistics condition;
and a display unit 603, configured to display a case statistics result corresponding to the case statistics condition.
The processing device based on the test case provided in this embodiment is similar to the technical scheme in the processing method based on the test case provided in any one of the foregoing embodiments, and its implementation principle and technical effect are similar and will not be repeated.
Fig. 7 is a schematic structural diagram of a processing device based on a test case according to a fourth embodiment of the present application, and on the basis of the third embodiment, as shown in fig. 7, the device further includes: an acquisition unit 701;
an obtaining unit 701, configured to obtain, before the receiving unit 601 receives a current operation, a mind map test case file input by a user, where the mind map test case file includes a plurality of test cases, each test case in the plurality of test cases has an icon identifier, and the icon identifier is used to indicate an execution result of the test case;
the determining unit 602 is specifically configured to determine a case statistics result based on icon identifiers of all test cases corresponding to the case statistics conditions in the mind map test case file.
Further, the case statistics conditions include a first statistics condition, the preset button control includes the first button control, and the case statistics results include the number of different execution results of all test cases corresponding to the first statistics condition.
Further, each test case in the plurality of test cases corresponds to a link, at least one level of non-leaf nodes and one leaf node are sequentially arranged on the link, the initial positions of all the links correspond to the same non-leaf node, and the leaf node is provided with an icon identifier corresponding to the test case;
further, the determining unit 602 is further configured to determine, based on the icon identifiers on all the leaf nodes included in each non-leaf node, a statistics set corresponding to each non-leaf node, where the statistics set includes the number of different execution results corresponding to all the leaf nodes included in the non-leaf node, before the obtaining unit 701 obtains the mind map test case file;
the determining unit 602 is specifically configured to determine a non-leaf node indicated by the first statistics condition, and determine a statistics set corresponding to the indicated non-leaf node as a use case statistics result.
Further, the case statistics conditions comprise second statistics conditions, the preset button control comprises the second button control, and the case statistics result comprises names of all test cases corresponding to the second statistics conditions.
Further, the second statistical condition includes any one or more of the following: execution pass case name, execution fail case name, execution block case name, no applicable case name, no execution case name.
The processing device based on the test case provided in this embodiment is similar to the technical scheme in the processing method based on the test case provided in any one of the foregoing embodiments, and its implementation principle and technical effect are similar and will not be repeated.
Fig. 8 is a schematic structural diagram of a processing device based on a test case according to a fifth embodiment of the present application, as shown in fig. 8, a memory 801 and a processor 802; wherein the memory 801 is for storing a computer program.
The processor 802 executes a computer program in the memory 801 to implement the technical solution of the test case-based processing method according to any of the implementation manners provided in the foregoing embodiments.
The application provides a computer readable storage medium, in which computer executable instructions are stored, and the computer executable instructions are used to implement the technical scheme of the test case-based processing method in any implementation manner provided in the foregoing embodiments when being executed by a processor.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any adaptations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (7)

1. A test case based processing method, the method comprising:
receiving a current operation input by a user, wherein the current operation comprises the steps that the user inputs a case statistics condition and clicks a preset button control after inputting the case statistics condition;
determining a case statistical result corresponding to the case statistical condition according to the current operation, wherein the case statistical result is used for indicating a result of statistics on all test cases corresponding to the case statistical condition;
displaying the case statistics results corresponding to the case statistics conditions;
before the receiving the current operation of the user input, the method further comprises:
acquiring a mind map test case file input by a user, wherein the mind map test case file comprises a plurality of test cases, each test case in the plurality of test cases has an icon identification, and the icon identification is used for indicating an execution result of the test case;
the determining the case statistics result corresponding to the case statistics condition comprises the following steps:
determining the case statistical result based on icon identifications of all the test cases corresponding to the case statistical conditions in the mind-induced graph test case file;
the case statistics conditions comprise first statistics conditions, the preset button control comprises a first button control, and the case statistics results comprise the number of different execution results of all test cases corresponding to the first statistics conditions;
each test case in the plurality of test cases corresponds to a link, the link is sequentially provided with at least one level of non-leaf nodes and one leaf node, the initial positions of all the links correspond to the same non-leaf node, and the leaf node is provided with an icon identifier corresponding to the test case;
after the thinking guide diagram test case file input by the user is obtained, the method further comprises the following steps:
determining a statistical set corresponding to each non-leaf node based on icon identifications on all the leaf nodes contained in each non-leaf node, wherein the statistical set comprises the number of different execution results corresponding to all the leaf nodes contained in the non-leaf node; the determining the statistics set corresponding to each non-leaf node based on the icon identifications on all the leaf nodes included in each non-leaf node comprises the following steps: traversing to find all leaf nodes, judging which type of mark exists in the current leaf node aiming at each leaf node, adding 1 to the number of the mark of the icon recorded in all father nodes of the current leaf node, storing the mark in the hashmap, and taking all keys of the hashmap finally obtained by traversing as names of non-leaf nodes in the mind map test case file, wherein the corresponding value is a statistical set;
in the test case file based on the mind map, the icon identifiers of all test cases corresponding to the case statistics conditions are included, and the determining the case statistics result includes:
and determining the non-leaf node indicated by the first statistical condition, and determining a statistical set corresponding to the indicated non-leaf node as the use case statistical result.
2. The method of claim 1, wherein the case statistics include a second statistics, the preset button control includes a second button control, and the case statistics include names of all test cases corresponding to the second statistics.
3. The method of claim 2, wherein the second statistical condition comprises any one or more of: execution pass case name, execution fail case name, execution block case name, no applicable case name, no execution case name.
4. A processing device based on test cases is characterized in that the device comprises a receiving unit, a determining unit and a display unit, wherein,
the receiving unit is used for receiving the current operation input by the user, wherein the current operation comprises the user input of a case statistics condition and the user clicking a preset button control after the user input of the case statistics condition;
the determining unit is configured to determine, according to the current operation, a case statistics result corresponding to the case statistics condition, where the case statistics result is used to indicate a result of statistics for all test cases corresponding to the case statistics condition;
the display unit is used for displaying the use case statistical result corresponding to the use case statistical condition;
the apparatus further comprises: an acquisition unit;
the acquisition unit is used for acquiring a mind map test case file input by a user before the receiving unit receives the current operation, wherein the mind map test case file comprises a plurality of test cases, each test case in the plurality of test cases is provided with an icon identification, and the icon identification is used for indicating an execution result of the test case;
the determining unit is specifically configured to determine the case statistics result based on icon identifiers of all test cases corresponding to the case statistics conditions in the mind-map test case file;
the case statistics conditions comprise first statistics conditions, the preset button control comprises a first button control, and the case statistics results comprise the number of different execution results of all test cases corresponding to the first statistics conditions;
each test case in the plurality of test cases corresponds to a link, at least one level of non-leaf nodes and one leaf node are sequentially arranged on the link, the initial positions of all the links correspond to the same non-leaf node, and the leaf node is provided with an icon identifier corresponding to the test case;
further, the determining unit is further configured to determine, based on the icon identifiers on all the leaf nodes included in each non-leaf node after the obtaining unit obtains the mind map test case file, a statistics set corresponding to each non-leaf node, where the statistics set includes the number of different execution results corresponding to all the leaf nodes included in the non-leaf node; the determining the statistics set corresponding to each non-leaf node based on the icon identifications on all the leaf nodes included in each non-leaf node comprises the following steps: traversing to find all leaf nodes, judging which type of mark exists in the current leaf node aiming at each leaf node, adding 1 to the number of the mark of the icon recorded in all father nodes of the current leaf node, storing the mark in the hashmap, and taking all keys of the hashmap finally obtained by traversing as names of non-leaf nodes in the mind map test case file, wherein the corresponding value is a statistical set;
the determining unit is specifically configured to determine a non-leaf node indicated by the first statistics condition, and determine a statistics set corresponding to the indicated non-leaf node as a use case statistics result.
5. The apparatus of claim 4, wherein the case statistics include a second statistics, the preset button control includes a second button control, and the case statistics include names of all test cases corresponding to the second statistics.
6. A test case based processing device, comprising: a memory and a processor;
the memory is used for storing a computer program;
wherein the processor executes the computer program in the memory to implement the method of any of claims 1-3.
7. A computer readable storage medium having stored therein computer executable instructions which when executed by a processor are adapted to carry out the method of any of claims 1-3.
CN202010499707.7A 2020-06-04 2020-06-04 Processing method, device, equipment and storage medium based on test case Active CN111538673B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010499707.7A CN111538673B (en) 2020-06-04 2020-06-04 Processing method, device, equipment and storage medium based on test case

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010499707.7A CN111538673B (en) 2020-06-04 2020-06-04 Processing method, device, equipment and storage medium based on test case

Publications (2)

Publication Number Publication Date
CN111538673A CN111538673A (en) 2020-08-14
CN111538673B true CN111538673B (en) 2023-07-07

Family

ID=71978124

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010499707.7A Active CN111538673B (en) 2020-06-04 2020-06-04 Processing method, device, equipment and storage medium based on test case

Country Status (1)

Country Link
CN (1) CN111538673B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112214398B (en) * 2020-09-16 2022-03-22 武汉木仓科技股份有限公司 Method and equipment for acquiring execution efficiency and test efficiency of test case in xmind tool

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016141077A1 (en) * 2015-03-02 2016-09-09 Edico Genome, Inc. Bioinformatics systems, apparatuses, and methods executed on an integrated circuit processing platform
CN106033389A (en) * 2015-03-11 2016-10-19 腾讯科技(深圳)有限公司 A test use case display method and device
CN109558317A (en) * 2018-11-22 2019-04-02 网易(杭州)网络有限公司 The processing method and processing device of test case
CN109740122A (en) * 2018-12-11 2019-05-10 中国联合网络通信集团有限公司 The conversion method and device of mind map use-case file

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107741911A (en) * 2017-11-01 2018-02-27 广州爱九游信息技术有限公司 Interface test method, device, client and computer-readable recording medium
CN108874671A (en) * 2018-06-20 2018-11-23 上海哔哩哔哩科技有限公司 Testing case management, device, system and storage medium
CN111078567B (en) * 2019-12-19 2023-06-13 广州品唯软件有限公司 Report generation method, terminal and storage medium of automatic test platform

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016141077A1 (en) * 2015-03-02 2016-09-09 Edico Genome, Inc. Bioinformatics systems, apparatuses, and methods executed on an integrated circuit processing platform
CN106033389A (en) * 2015-03-11 2016-10-19 腾讯科技(深圳)有限公司 A test use case display method and device
CN109558317A (en) * 2018-11-22 2019-04-02 网易(杭州)网络有限公司 The processing method and processing device of test case
CN109740122A (en) * 2018-12-11 2019-05-10 中国联合网络通信集团有限公司 The conversion method and device of mind map use-case file

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
9th GMM-Symposium》.2018,1-7. *
Guerkan Uygur等.uC-Based ATE for Testing a DUT provided with Real-World Failure Models.《AmE 2018 - Automotive meets Electronics *
基于思维导图的测试用例设计平台的实现与应用;李宁等;《电子世界》;208-209 *

Also Published As

Publication number Publication date
CN111538673A (en) 2020-08-14

Similar Documents

Publication Publication Date Title
Lerch et al. Finding duplicates of your yet unwritten bug report
CN104699608B (en) Graphic User Interface software automatic test approach and device
US20030177417A1 (en) System and method for remote performance analysis and optimization of computer systems
CN110275878B (en) Service data detection method and device, computer equipment and storage medium
US10437717B2 (en) Defect reporting in application testing
Servant et al. Fuzzy fine-grained code-history analysis
CN111008154B (en) Android application automatic test method and system based on reinforcement learning
US20160103754A1 (en) Method and system for grading a computer program
CN109408385B (en) A kind of disfigurement discovery method based on mischief rule and classifying feedback
CN110515826A (en) A kind of software defect positioning method based on number frequency spectrum and neural network algorithm
CN111538673B (en) Processing method, device, equipment and storage medium based on test case
CN108845925B (en) Web page testing method and device, electronic equipment and computer readable medium
JP2012243125A (en) Causal word pair extraction device, causal word pair extraction method and program for causal word pair extraction
Petrulio et al. SZZ in the time of pull requests
JP2003029970A (en) Program quality management supporting device, program quality management supporting method, computer readable recording medium having program for making computer perform program quality management supporting method recorded thereon and program for making computer perform program quality management supporting method
CN113051262B (en) Data quality inspection method, device, equipment and storage medium
CN114676061A (en) Knowledge graph-based automatic firmware detection method
CN111341405B (en) Medical data processing system and method
CN113934638A (en) Automatic testing method
JP2017224185A (en) Bug contamination probability calculation program and bug contamination probability calculation method
CN111831535A (en) Code positioning method and device of test case and computer storage medium
Xu et al. A log-linear probabilistic model for prioritizing extract method refactorings
CN110825650B (en) Unit test coverage precision detection method and device
WO2024067039A1 (en) Application automated testing method, electronic device, and computer readable medium
Behringer et al. Unobtrusive Integration of Data Quality in Interactive Explorative Data Analysis.

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant