CN104615536B - A kind of test case control method and electronic equipment - Google Patents

A kind of test case control method and electronic equipment Download PDF

Info

Publication number
CN104615536B
CN104615536B CN201510047542.9A CN201510047542A CN104615536B CN 104615536 B CN104615536 B CN 104615536B CN 201510047542 A CN201510047542 A CN 201510047542A CN 104615536 B CN104615536 B CN 104615536B
Authority
CN
China
Prior art keywords
test
editing
test case
case
interface
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
CN201510047542.9A
Other languages
Chinese (zh)
Other versions
CN104615536A (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.)
Beijing Sogou Technology Development Co Ltd
Original Assignee
Beijing Sogou Technology Development 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 Beijing Sogou Technology Development Co Ltd filed Critical Beijing Sogou Technology Development Co Ltd
Priority to CN201510047542.9A priority Critical patent/CN104615536B/en
Publication of CN104615536A publication Critical patent/CN104615536A/en
Application granted granted Critical
Publication of CN104615536B publication Critical patent/CN104615536B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • User Interface Of Digital Computer (AREA)

Abstract

The present invention relates to data processing field, a kind of test case control method and electronic equipment are disclosed, to solve the technical problem that test case writer can not be allowed quickly and easily to look back previous test case or follow-up test case maintenance inconvenience when being write to test case in the prior art.This method is applied in electronic equipment, the control interface of case management system is shown on the display unit of electronic equipment, control interface, which includes outline editing area and use-case editing area, method, to be included:Detection obtains the first operation for control interface;Judge whether the first operation meets the first preparatory condition;When the first operation meets the first preparatory condition, the display content of control interface is adjusted to the second display content by the first display content.Previous test case and the technique effect that preferably can be safeguarded to test case can quickly and easily be looked back by having reached test case writer.

Description

A kind of test case control method and electronic equipment
Technical field
The present invention relates to data processing field, more particularly to a kind of test case control method and electronic equipment.
Background technology
Test case refers to one group of test input, execution condition and the expected results worked out for some special objective, To test some Program path or examine whether meet some particular demands, test outline refers to the collection of a collection of test case Close, test case can be write in several ways in the prior art, two ways therein is set forth below and is introduced.
The first, is write by test and management instrument at present on the market to test case, for test case It is all first to create use-case outline (use-case set) to write, then use-case is created under specific outline, and the process created is all Create one by one.In this flow, use-case people designer needs ceaselessly to click the " new " button, and opens a new table, Turned off after inserting data, then open next use-case.
Second, using word or excel by the way of edit or manage use-case, by office editting function, Case designing personnel are saved trouble much really when editing use-case.
Above there is problems with the first mode for writing test case:
1. test case writer can not be allowed quickly and easily to look back previous test case;
2. it can not allow test case writer is convenient to enter edlin to test case.
Problems be present in second of mode for writing test case of the above:
1. follow-up maintenance and use-case evaluation link, very inconvenient, it is necessary to which document is passed, it is impossible to association well With work, be also inconvenient to retrieve, compare;
2. during assigned tasks, since it is desired that document is passed, so it is inconvenient during division use-case.
The content of the invention
The present invention provides a kind of test case control method and electronic equipment, to solve in the prior art to test case Test case writer can not be allowed quickly and easily to look back previous test case or follow-up test use-case when being write Safeguard inconvenient technical problem.
In a first aspect, the embodiment of the present invention provides a kind of test case control method, applied in electronic equipment, its feature It is, the control interface of case management system is shown on the display unit of the electronic equipment, and the control interface includes big Guiding principle editing area and use-case editing area, the outline editing area show the directory information of outline, the use-case editing area Domain shows the editing view of outline, and at least two editors circle of at least two test cases are included in the editing view Face, at least two editing interface show that methods described includes successively according to putting in order corresponding to the directory information:
Detection obtains the first operation for the control interface;
Judge whether first operation meets the first preparatory condition;
When the described first operation meets first preparatory condition, the display content of the control interface is shown by first Show that content is adjusted to the second display content.
Optionally, it is described to judge whether first operation meets the first preparatory condition, be specially:Judge first behaviour Whether it is the insertion operation that the first test case is inserted in the control interface;
The display content by the control interface is adjusted to the second display content by the first display content, is specially:
The first editing interface of first test case is inserted in the editing view.
Optionally, it is described to judge whether first operation meets the first preparatory condition, be specially:Judge first behaviour Whether it is the edit operation for entering edlin to the first editing interface at least two editing interface;
The display content by the control interface is adjusted to the second display content by the first display content, is specially:
The edit operation is responded, the parameter information of first editing interface is adjusted.
Optionally, it is described to judge whether first operation meets the first preparatory condition, be specially:Judge first behaviour Whether be the display content for adjusting the use-case editing area first adjustment operation;
The display content by the control interface is adjusted to the second display content by the first display content, is specially:
It is sequentially adjusted in the display location of each editing interface at least two editing interface.
Optionally, it is described to judge whether first operation meets the first preparatory condition, be specially:Judge first behaviour Whether be adjust the first test case display location second adjustment operation;
The display content by the control interface is adjusted to the second display content by the first display content, is specially:
The first editing interface corresponding to first test case is adjusted to and the first position by first position The different second places.
Optionally, it is described to judge whether first operation meets the first preparatory condition, be specially:Judge first behaviour Whether it is the duplication operation for replicating the first test case;
The display content by the control interface is adjusted to the second display content by the first display content, specific bag Include:
Threeth position corresponding with the described first operation adds the second editing interface in the editing view, and described the Two editing interfaces are identical with the parameter information of the first editing interface of first test case.
Optionally, methods described also includes:
After detection obtains the second operation of the second preparatory condition of satisfaction, the testing requirement of the second test case is jumped to Interface, the testing requirement interface include demand directory area and test code region, and the demand directory area includes described At least one index information corresponding at least one testing requirement of second test case;
Response is directed to the selection operation of the first index information at least one index information, the first index letter First testing requirement of corresponding second test case of breath;
The first test code corresponding to first index information is called in the test zone, to test described first Demand is tested.
Optionally, it is described to call the first test code corresponding to first index information in the test zone, specifically Including:
Determine multiple test codes corresponding to first index information;
Based on the parameter information of second test case, first test is filtered out from the multiple test code Code.
Optionally, methods described also includes:
At least two users are obtained the 3rd test case to be carried out testing corresponding at least two groups of test datas respectively;
Based at least two groups of Test data generation aggregation test process;
The result of the aggregation test process is analyzed, believed with the failure at least two groups of test datas described in determination Breath;
Receive the modification operation that user is carried out based on the fault message to the 3rd test case;
The 3rd test case after operation of modifying further is tested.
Optionally, methods described also includes:
Index value is set respectively to all test cases that the editing view is included, so that other systems can pass through Test case corresponding to the index value calling.
Second aspect, the embodiment of the present invention provide a kind of electronic equipment, shown on the display unit of the electronic equipment The control interface of case management system, the control interface include outline editing area and use-case editing area, and the outline is compiled The directory information that region shows outline is collected, the use-case editing area shows the editing view of outline, the editing view In include at least two editing interfaces of at least two test cases, at least two editing interface is believed according to the catalogue Corresponding the putting in order of breath shows that the electronic equipment includes successively:
Detection module, for detecting the first operation obtained for the control interface;
Judge module, for judging whether first operation meets the first preparatory condition;
Adjusting module, for when the described first operation meets first preparatory condition, by the aobvious of the control interface Show that content is adjusted to the second display content by the first display content.
Optionally, the judge module, is specifically used for:Judge whether first operation is to be inserted in the control interface Enter the insertion operation of the first test case;
The adjusting module, is specifically used for:
The first editing interface of first test case is inserted in the editing view.
Optionally, the judge module, is specifically used for:Judge whether first operation is to be edited to described at least two The first editing interface in interface enters the edit operation of edlin;
The adjusting module, is specifically used for:
The edit operation is responded, the parameter information of first editing interface is adjusted.
Optionally, the judge module, is specifically used for:Judge whether first operation is the adjustment use-case editing area First adjustment operation of the display content in domain;
The adjusting module, is specifically used for:
It is sequentially adjusted in the display location of each editing interface at least two editing interface.
Optionally, the judge module, is specifically used for:Judge whether first operation is the first test case of adjustment Second adjustment operation of display location;
The adjusting module, is specifically used for:
The first editing interface corresponding to first test case is adjusted to and the first position by first position The different second places.
Optionally, the judge module, is specifically used for:Judge whether first operation is to replicate the first test case Replicate operation;
The adjusting module, is specifically used for:
Threeth position corresponding with the described first operation adds the second editing interface in the editing view, and described the Two editing interfaces are identical with the parameter information of the first editing interface of first test case.
Optionally, the electronic equipment also includes:
Jump module, after obtaining the second operation of the second preparatory condition of satisfaction in detection, jump to the second test The testing requirement interface of use-case, the testing requirement interface include demand directory area and test code region, the demand mesh Record at least one index information corresponding at least one testing requirement of the region comprising second test case;
Respond module, for responding the selection operation for the first index information being directed at least one index information, First index information corresponds to the first testing requirement of second test case;
Calling module, for calling the first test code corresponding to first index information in the test zone, with First testing requirement is tested.
Optionally, the calling module, is specifically included:
Determining unit, for determining multiple test codes corresponding to first index information;
Screening unit, for the parameter information based on second test case, screened from the multiple test code Go out the first test code.
Optionally, the electronic equipment also includes:
Acquisition module, the 3rd test case is carried out testing corresponding at least two respectively for obtaining at least two users Group test data;
Generation module, for based at least two groups of Test data generation aggregation test process;
Analysis module, for analyzing the result of the aggregation test process, with least two groups of tests described in determination Fault message in data;
Receiving module, the modification behaviour carried out for receiving user based on the fault message to the 3rd test case Make;
Test module, for further being tested the 3rd test case after operation of modifying.
Optionally, the electronic equipment also includes:
Setup module, for setting index value respectively to all test cases that the editing view is included, so that its He can pass through test case corresponding to index value calling at system.
The present invention has the beneficial effect that:
Due in embodiments of the present invention, there is provided a kind of test case control method, applied in electronic equipment, electronics The control interface of case management system is shown on the display unit of equipment, control interface includes outline editing area and use-case is compiled Region is collected, outline editing area shows the directory information of outline, and use-case editing area shows the editing view of outline, editor Include at least two editing interfaces of at least two test cases in view, at least two editing interfaces are according to directory information institute Corresponding put in order shows that method includes successively:Detection obtains the first operation for control interface;Judging the first operation is The first preparatory condition of no satisfaction;When the first operation meets the first preparatory condition, the display content of control interface is shown by first Show that content is adjusted to the second display content, that is to say, that in test case compiling procedure, use-case editing area is shown at least At least two editing interfaces of two test cases, so test case writer can quickly and easily look back previous survey Example on probation, and test case writer easily can enter edlin to test case, ensure that user in design use-case When thinking continuity, user can be made to bring good Experience Degree;
Also, due to be by use-case management system editor's test case, so solve using excel or word etc. side Can not be safeguarded well when formula is to manage use-case, version management, retrieval, cooperation and the problems such as assigned tasks.
Brief description of the drawings
Fig. 1 is the schematic diagram of the control interface of case management system in the embodiment of the present invention;
Fig. 2 is the flow chart of test case control method in the embodiment of the present invention;
Fig. 3 is to call the flow of the first test code in test zone in test case control method of the embodiment of the present invention Figure;
Fig. 4 is the schematic diagram at testing requirement interface in the embodiment of the present invention;
Fig. 5 is the flow chart modified in test case control method of the embodiment of the present invention to the first test case;
Fig. 6 is the structure chart of electronic equipment in the embodiment of the present invention.
Embodiment
The present invention provides a kind of test case control method and electronic equipment, to solve in the prior art to test case Test case writer can not be allowed quickly and easily to look back previous test case or follow-up test use-case when being write Safeguard inconvenient technical problem.
Technical scheme in the embodiment of the present application is the above-mentioned technical problem of solution, and general thought is as follows:
A kind of test case control method is provided, applied in electronic equipment, is shown on the display unit of electronic equipment There is the control interface of use-case management system, control interface includes outline editing area and use-case editing area, outline editing area The directory information of outline is shown, use-case editing area shows the editing view of outline, at least two are included in editing view At least two editing interfaces of individual test case, at least two editing interfaces are according to putting in order successively corresponding to directory information It has been shown that, method include:Detection obtains the first operation for control interface;Judge whether the first operation meets the first default bar Part;When the first operation meets the first preparatory condition, the display content of control interface is adjusted to second by the first display content Display content, that is to say, that in test case compiling procedure, use-case editing area shows at least two test cases extremely Few two editing interfaces, so test case writer can quickly and easily look back previous test case, and are tested Use-case writer easily can enter edlin to test case, ensure that thinking of the user when designing use-case links up Property, user can be made to bring good Experience Degree;
Also, due to be by use-case management system editor's test case, so solve using excel or word etc. side Can not be safeguarded well when formula is to manage use-case, version management, retrieval, cooperation and the problems such as assigned tasks.
In order to be better understood from above-mentioned technical proposal, below by accompanying drawing and specific embodiment to technical solution of the present invention It is described in detail, it should be understood that the specific features in the embodiment of the present invention and embodiment are to the detailed of technical solution of the present invention Thin explanation, rather than the restriction to technical solution of the present invention, in the case where not conflicting, the embodiment of the present invention and embodiment In technical characteristic can be mutually combined.
In a first aspect, the embodiment of the present invention provides a kind of test case control method, applied in electronic equipment, such as Fig. 1 It is shown, the control interface of case management system is shown on the display unit of electronic equipment, control interface includes outline editing area Domain and use-case editing area, outline editing area show the directory information of outline, and use-case editing area shows the volume of outline View is collected, at least two editing interfaces of at least two test cases are included in editing view, at least two editing interfaces are pressed Shown successively according to putting in order corresponding to directory information, wherein Fig. 1 left side is exactly the directory information of a tree-shaped outline, And be then an editing view for corresponding to directory information on right side, the editing view of every outline shows successively in editing view Show, wherein, some outlines can include one or more test cases, and some outlines do not include test case then, if outline is wrapped Containing test case, then in editing view corresponding to outline test case corresponding to display editing interface, outline 1.1 in Fig. 1 Editing view in include test case:Case1 editing interface;Test case is included in outline 1.1.1 editing view: Case2 editing interface;Then comprising test case case3, test case case4, test case in the editing view of outline 1.2 Case5 editing interface, and limited by the size of use-case editing area, then do not show it in the editing view of outline 1.3 The editing interface of corresponding test case, that is, 5 editing interfaces corresponding to 5 test cases are contained in Fig. 1.
Fig. 2 is refer to, this method comprises the following steps:
Step S201:Detection obtains the first operation for control interface;
Step S202:Judge whether the first operation meets the first preparatory condition;
Step S203:When the first operation meets the first preparatory condition, by the display content of control interface by the first display Content is adjusted to the second display content.
In step S201, the first operation is, for example,:The operation of click button, the operation for clicking on shortcut, produce gesture Operation etc., it is which kind of operation for the first operation, the embodiment of the present invention no longer itemizes, and is not restricted.
In step S202, in order to realize that the difference to test case controls, the first different preparatory conditions can be set, under Face is enumerated five kinds therein and is introduced, and certainly, in specific implementation process, is not limited to following five kinds of situations.
The first, judges whether the first operation meets the first preparatory condition, is specially:Judge whether the first operation is to control The insertion operation of the first test case is inserted in interface processed.
For example, that is, the first preparatory condition that the first test case is inserted in control interface can be arranged on, the One preparatory condition is, for example,:The keyboard shortcut of the insertion button of click outline editing view, click " CTRL "+" ENTER " keys Etc., in this case, if detecting that the first operation meets the first preparatory condition, the can be inserted in control interface One test case.
Second, judge whether the first operation meets the first preparatory condition, be specially:Judge whether the first operation is to extremely The first editing interface in few two editing interfaces enters the edit operation of edlin;
For example, that is, the first editing interface that can be arranged in control interface is compiled to the first test case The first preparatory condition collected, the first preparatory condition are, for example,:The operation of character, the operation for pasting character etc. are inputted, this In the case of, if detecting that the first operation meets the first preparatory condition, edlin can be entered to the first editing interface, such as: Change use-case purpose, use-case step and other attributes of the first editing interface etc..
The third, judges whether the first operation meets the first preparatory condition, is specially:Judge whether the first operation is adjustment The adjustment operation of the display content of use-case editing area;
For example, that is, can set adjustment use-case editing area display content the first preparatory condition, first Preparatory condition is, for example,:Scroll-up/down mouse, dragging progress bar etc..In this case, if detecting that the first operation is expired The first preparatory condition of foot, then can be overall upwards by the content shown by use-case editing area, downwards, to the left or move right It is dynamic.
4th kind, judge whether the first operation meets the first preparatory condition, be specially:Judge whether the first operation is adjustment The adjustment operation of the display location of first test case;
For example, that is, can set adjustment the first test case display location the first preparatory condition, wherein First preparatory condition is, for example,:Drag operation, click on such as keyboard shortcut of " CTRL "+"+" key etc..In such case Under, if detecting that the first operation meets the first preparatory condition, the display location of the first test case can be adjusted, Such as:Assuming that the first test case is:Case4, it positioned at the editing view where outline 1.2, then can pass through first originally The editing view that first test case can be moved to where outline 1.1 by operation;Assuming that the first test case is:Case2, its The original editing view being located at where outline 1.1.1, then the first test case can be moved to by outline 1.2 by the first operation The editing view at place etc..
5th kind, judge whether the first operation meets the first preparatory condition, be specially:Judge whether the first operation is duplication The duplication operation of first test case;
For example, that is, the first preparatory condition replicated to the first test case can be set, wherein first Preparatory condition is, for example,:The keyboard shortcut of such as " CTRL "+" C " keys is first clicked on for the first test case, then the 3rd Such as keyboard shortcut of " CTRL "+" V " keys etc. is clicked in position, in such a case, it is possible to the ginseng to the first test case Number information is replicated, by the parameter value and the first test case phase that replicate the second test case each of which field obtained Together.
6th kind, judge whether the first operation meets the first preparatory condition, be specially:Judge whether the first operation is adjustment The operation of the directory information of outline;
For example, that is, the first preparatory condition being adjusted to the directory information of outline can be set, wherein One preparatory condition for example comprising:The shortcut such as " CTRL "+"+", " CTRL "+"-", " CTRL "+" ↑ ", " CTRL "+" ↓ ", " del " Mode, drag operation etc., the adjustment to the directory information of outline can be realized based on this.
In step S203, based on the difference of the first preparatory condition, by the display content of control interface by the first display content It is also different to be adjusted to the mode of the second display content, is set forth below five kinds therein and is introduced, certainly, in specific implementation process In, it is not limited to following five kinds of situations.
The first, the first operation is that the insertion operation of the first test case is inserted in control interface, then by control interface Display content the second display content is adjusted to by the first display content, be specially:
The first editing interface of the first test case is inserted in editing view.
For example, the difference based on the targeted position of the first operation, inserts the first editing interface in editing view Position it is also different, such as:If current outline is outline 1.1, can outline 1.1 least significant end (namely case1 it The first editing interface is inserted afterwards);In another example:The test case that active user is editing is case3, and for test case Case3 is compiled to be finished, then user click on such as " CTRL "+" ENTER " keys keyboard shortcut, then can be in test case The editing interface of a test case is inserted after case3, such as:Insert test case case4 editing interface etc..Specific In implementation process, it can be arranged on different positions according to the actual requirements and insert the first editing interface, to this embodiment of the present invention No longer itemize, and be not restricted.
In addition, now cursor is also corresponding switches to the first editing interface, and then allow users to continue to write the first survey Example on probation, without causing the thinking of user to be interrupted, and then makes to write more smooth during test case.
Second, the first operation is to enter the editor behaviour of edlin to the first editing interface at least two editing interfaces Make, the display content of control interface is adjusted to the second display content by the first display content, be specially:
Response editing operates, and is adjusted with the parameter information to the first editing interface.
For example, user can adjust use-case purpose, use-case step and other attributes etc. by edit operation, wherein Use-case purpose is adjusted for example,:Input use-case purpose, use-case purpose is modified etc., in this case, control The display content at interface processed can also change.
The third, the first operation operates for the first adjustment of the display content of adjustment use-case editing area, by control interface Display content the second display content is adjusted to by the first display content, be specially:
It is sequentially adjusted in the display location of each editing interface at least two editing interfaces.
For example, if the first operation is the operation of roll mouse to the left, the aobvious of use-case editing area can be controlled Show that content integrally moves right, and then the display location of at least two editing interfaces is moved right successively;If the first operation For the operation for the mouse that scrolls right, then the display content of use-case editing area can be controlled integrally to be moved to the left, and then make at least The display location of two editing interfaces is moved to the left successively;If the first operation is the operation for the mouse that scrolls up, can control The display content of use-case editing area processed integrally moves down, and then makes the display location of at least two editing interfaces downward successively It is mobile;If the first operation is to scroll down through the operation of mouse, can control use-case editing area display content it is overall to Upper movement, and then the display location of at least two editing interfaces is moved up successively etc..
4th kind, first operation whether be adjust the first test case display location second adjustment operation, will control The display content at interface is adjusted to the second display content by the first display content, is specially:
The first editing interface corresponding to first test case is adjusted to different from first position by first position Two positions.
As an example it is assumed that the first operation is drag operation, then the first position institute where the starting point of the first operation is right The editing interface answered be the first editing interface (such as:User is placed on case1 in mouse, then long-press mouse, pulls test Use-case case1, then the editing interface corresponding to test case case1 is the first editing interface), wherein, if drag operation is stopped If position only is located at the use-case editing area on right side, then the position that drag operation stops is then the second place;If pull If the position that operation stops is located at the outline editing area in left side, then the second place is corresponding to the position that drag operation stops Outline editing view region, and then the first editing interface can easily be moved based on this.
5th kind, the first operation is replicates the duplication of the first test case operation, by the display content of control interface by the One display content is adjusted to the second display content, specifically includes:
Threeth position corresponding with the first operation adds the second editing interface in editing view, the second editing interface with The parameter information of first editing interface of the first test case is identical.
For example, because many test cases can be reused, if two with identical function tests are used If example also needs Reparametrization and writes code, then it can cause the waste of human resources, so for parameter phase Same or similar test case, then can be generated by way of duplication.Wherein, if user needs to replicate the first test case (such as:Case1), then test case case1 is chosen first, then clicks on the keyboard shortcut of such as " CTRL "+" C " keys, so The keyboard shortcut of such as " CTRL "+" V " keys then is clicked in the 3rd position afterwards, then one second survey can be generated in the 3rd position The second editing interface (being also equivalent to generate second test case by copy mode) of example on probation, the second editor circle The parameter information in face is identical with the parameter information of the first test case, such as:Field value is identical, attribute is identical etc..
6th kind, first operation be:The operation of the directory information of outline is adjusted, by the display content of control interface by first Display content is adjusted to the second display content, specifically includes:
The directory information of outline is adjusted.
Wherein it is possible to the level of some outline in adjusting the directory information of outline, current location and delete outline, example Such as, if the first operation is the keyboard shortcut of such as " CTRL "+"+", by the level+1 of current outline;If the first operation For such as " CTRL "+"-" keyboard shortcut then by the level -1 of current outline;If the first operation is such as " CTRL "+" ↑ " Keyboard shortcut then by current outline by preceding movement one;If the first operation is the shortcut side of such as " CTRL "+" ↓ " Formula, then current outline is moved rearwards one;If the first operation is for example " del " keyboard shortcut, delete current big Guiding principle etc..Certainly, it is only a citing that the above first, which operates and to the corresponding relation between the adjustment of outline, in practical application In, different first can be set to operate and to the corresponding relation between the adjustment of outline, to this present invention according to the actual requirements Embodiment no longer itemizes, and is not restricted.
As further preferred embodiment, Fig. 3 is refer to, method also includes:
Step S301:After detection obtains the second operation of the second preparatory condition of satisfaction, the second test case is jumped to Testing requirement interface, testing requirement interface includes demand directory area and test code region, and demand directory area includes the At least one index information corresponding at least one testing requirement of two test cases;
Step S302:Response is directed to the selection operation of the first index information at least one index information, the first index First testing requirement of corresponding second test case of information;
Step S303:The first test code corresponding to the first index information is called in test zone, to be needed to the first test Ask and tested.
Due in such scheme, provide the user an automatized script development platform, automatic script confession can be provided Development of user is write, so improve the efficiency tested test case.
In step S301, the second preparatory condition is, for example,:Double-click the title of the second test case, double-click the second editing interface Etc., the second different preparatory conditions can be according to the actual requirements set, this embodiment of the present invention is no longer itemized, and It is not restricted.
Fig. 4 is refer to, is a testing requirement interface, wherein left side is demand directory area, contains the second test case At least one testing requirement corresponding at least one index information, testing requirement is, for example,:Repair function, smoke test, Installation unloading etc..
In step S302, selection operation is, for example,:Click the operation of the first index information, double-click the behaviour of the first index information Make etc., wherein the title of the first index information is identical with the first testing requirement, such as:First index information is entitled:Installation Unloading, then the first testing requirement is also installation unloading.
In step S303, the first index information only corresponding one kind can test code, in this case, directly test Call the test code in region;First index information can also correspond to it is a variety of test codes (such as:Java codes, c++ generations Code etc.), in this case, then need to select a kind of test code from this variety of test code to the first test case Tested, wherein a kind of test code can be selected from a variety of test codes at random, can also the selection based on user Operation selects a kind of test code from this variety of test code, described in test zone as further preferred embodiment The first test code corresponding to the first index information is called, is specifically included:
Determine multiple test codes corresponding to the first index information;
Based on the parameter information of the second test case, the first test code is filtered out from multiple test codes.
Specifically, that is, selected first test code and the second test case parameter information it is corresponding, In this case, it can ensure that the first selected test code can more be bonded the second test case, and then be more conducive to survey The progress of examination.
As further preferred embodiment, Fig. 5 is refer to, method also includes:
Step S501:At least two users are obtained the 3rd test case to be carried out testing corresponding at least two groups of surveys respectively Try data;
Step S502:Based at least two groups of Test data generation aggregation test process;
Step S503:The result for assembling test process is analyzed, to determine the failure at least two groups of test datas Information;
Step S504:Receive the modification operation that user is carried out based on fault message to the 3rd test case;
Step S505:The first test case after operation of modifying further is tested.
In step S501, can use different types of tester (such as:Expert, beginner etc.) surveyed respectively to the 3rd Example on probation is tested, and then obtains one group of test result respectively, such as:Assuming that tester include tester first, tester second, Tester third, and then the 3rd test case is tested respectively by these three testers, and then obtains three groups of test results;
In step S502, after at least two groups of test results are obtained, by this, at least two groups of test results are combined, just Aggregation test process can be obtained;
In step S503, after the result to assembling test process is analyzed, it may be determined that go out following fault message: 1. common point of failure, such as:Trouble point A is all included in the test result of tester's first and tester's second, it is determined that be out of order point A For the common point of failure of tester's first and tester's second;2. it is abnormal in indivedual test process, such as:The test result of tester's first In include trouble point B, then the test result of the position is all normal in tester's second and tester C test result, then says Bright trouble point is exception in indivedual test process of tester's first etc..
In step S504, it is determined that after these fault messages, these fault messages can be supplied to electronic equipment User, such as:These fault messages are shown in the display unit of electronic equipment, user there are these in test process is recognized After failure, it is possible to which operation of being modified to the 3rd test case, modification operation are, for example,:Manual modification, coordination, change are matched somebody with somebody Put etc..
In step S505, after being modified to the 3rd test case, the 3rd test case has higher fault-tolerance, And the 3rd test case can be tested again based on this, by repeatedly circulation, it becomes possible to ensure the 3rd test case Reliability.
As further preferred embodiment, method also includes:
Index value is set respectively to all test cases that editing view is included, so that other systems can pass through index Test case corresponding to value calling.
By such scheme, the technique effect for being associated test case and other systems can be facilitated by having reached, its In, it is based on different systems, test case mode associated with it is also different, it is set forth below three kinds therein and is introduced, Certainly, in specific implementation process, following three kinds of situations are not limited to.
The first, test case is applied to task management system
When task management system needs newly-built task, the rope of all test cases in case management system is obtained first Draw value, then the index value of all test cases is shown in the interface of case management system in the form of tree, by user The test case that selection needs to use, task corresponding to the Test cases technology that last task management system is selected based on user, And perform.
Second, test case is applied to automatization test system
Test case write completion after, code will be provided to server, and the index value of test case is carried Automatization test system is supplied, automatization test system determines that test after the index of test case corresponding to receiving Use-case carries out submission code, in this case, just by index value obtain corresponding to code, and test case is entered based on this Row test.
The third, test case is applied to requirement management systems
Under normal circumstances, each testing requirement can include a demand ID, and case management system can be given birth to by demand ID Into one group of test case (index value of this group of test case associates with this demand ID).
Due to based on such scheme, use example with other systems establishes associating for closed loop after creating, so improve The test of product, the efficiency of management and task establish efficiency.
Second aspect, based on same inventive concept, the embodiment of the present invention provides a kind of electronic equipment, the electronic equipment The control interface of case management system is shown on display unit, the control interface includes outline editing area and use-case editor Region, the outline editing area show the directory information of outline, and the editor that the use-case editing area shows outline regards Scheme, at least two editing interfaces of at least two test cases, at least two editor circle are included in the editing view Face is shown successively according to putting in order corresponding to the directory information, refer to Fig. 6, and the electronic equipment includes:
Detection module 60, for detecting the first operation obtained for the control interface;
Judge module 61, for judging whether first operation meets the first preparatory condition;
Adjusting module 62, for described first operation meet first preparatory condition when, by the control interface Display content is adjusted to the second display content by the first display content.
Optionally, the judge module 61, is specifically used for:Judge whether first operation is in the control interface Insert the insertion operation of the first test case;
The adjusting module 62, is specifically used for:
The first editing interface of first test case is inserted in the editing view.
Optionally, the judge module 61, is specifically used for:Judge whether first operation is to be compiled to described at least two The first editing interface in editing interface enters the edit operation of edlin;
The adjusting module 62, is specifically used for:
The edit operation is responded, the parameter information of first editing interface is adjusted.
Optionally, the judge module 61, is specifically used for:Judge whether first operation is the adjustment use-case editor First adjustment operation of the display content in region;
The adjusting module 62, is specifically used for:
It is sequentially adjusted in the display location of each editing interface at least two editing interface.
Optionally, the judge module 61, is specifically used for:Judge whether first operation is the first test case of adjustment Display location second adjustment operation;
The adjusting module 62, is specifically used for:
The first editing interface corresponding to first test case is adjusted to and the first position by first position The different second places.
Optionally, the judge module 61, is specifically used for:Judge whether first operation is to replicate the first test case Duplication operation;
The adjusting module 62, is specifically used for:
Threeth position corresponding with the described first operation adds the second editing interface in the editing view, and described the Two editing interfaces are identical with the parameter information of the first editing interface of first test case.
Optionally, the electronic equipment also includes:
Jump module, after obtaining the second operation of the second preparatory condition of satisfaction in detection, jump to the second test The testing requirement interface of use-case, the testing requirement interface include demand directory area and test code region, the demand mesh Record at least one index information corresponding at least one testing requirement of the region comprising second test case;
Respond module, for responding the selection operation for the first index information being directed at least one index information, First index information corresponds to the first testing requirement of second test case;
Calling module, for calling the first test code corresponding to first index information in the test zone, with First testing requirement is tested.
Optionally, the calling module, is specifically included:
Determining unit, for determining multiple test codes corresponding to first index information;
Screening unit, for the parameter information based on second test case, screened from the multiple test code Go out the first test code.
Optionally, the electronic equipment also includes:
Acquisition module, the 3rd test case is carried out testing corresponding at least two respectively for obtaining at least two users Group test data;
Generation module, for based at least two groups of Test data generation aggregation test process;
Analysis module, for analyzing the result of the aggregation test process, with least two groups of tests described in determination Fault message in data;
Receiving module, the modification behaviour carried out for receiving user based on the fault message to the 3rd test case Make;
Test module, for further being tested the 3rd test case after operation of modifying.
Optionally, the electronic equipment also includes:
Setup module, for setting index value respectively to all test cases that the editing view is included, so that its He can pass through test case corresponding to index value calling at system.
The one or more embodiments of the present invention, at least have the advantages that:
Due in embodiments of the present invention, there is provided a kind of test case control method, applied in electronic equipment, electronics The control interface of case management system is shown on the display unit of equipment, control interface includes outline editing area and use-case is compiled Region is collected, outline editing area shows the directory information of outline, and use-case editing area shows the editing view of outline, editor Include at least two editing interfaces of at least two test cases in view, at least two editing interfaces are according to directory information institute Corresponding put in order shows that method includes successively:Detection obtains the first operation for control interface;Judging the first operation is The first preparatory condition of no satisfaction;When the first operation meets the first preparatory condition, the display content of control interface is shown by first Show that content is adjusted to the second display content, that is to say, that in test case compiling procedure, use-case editing area is shown at least At least two editing interfaces of two test cases, so test case writer can quickly and easily look back previous survey Example on probation, and test case writer easily can enter edlin to test case, ensure that user in design use-case When thinking continuity, user can be made to bring good Experience Degree;
Also, due to be by use-case management system editor's test case, so solve using excel or word etc. side Can not be safeguarded well when formula is to manage use-case, version management, retrieval, cooperation and the problems such as assigned tasks.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or computer program Product.Therefore, the present invention can use the reality in terms of complete hardware embodiment, complete software embodiment or combination software and hardware Apply the form of example.Moreover, the present invention can use the computer for wherein including computer usable program code in one or more The computer program production that usable storage medium is implemented on (including but is not limited to magnetic disk storage, CD-ROM, optical memory etc.) The form of product.
The present invention is the flow with reference to method according to embodiments of the present invention, equipment (system) and computer program product Figure and/or block diagram describe.It should be understood that can be by every first-class in computer program instructions implementation process figure and/or block diagram Journey and/or the flow in square frame and flow chart and/or block diagram and/or the combination of square frame.These computer programs can be provided The processors of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce A raw machine so that produced by the instruction of computer or the computing device of other programmable data processing devices for real The device for the function of being specified in present one flow of flow chart or one square frame of multiple flows and/or block diagram or multiple square frames.
These computer program instructions, which may be alternatively stored in, can guide computer or other programmable data processing devices with spy Determine in the computer-readable memory that mode works so that the instruction being stored in the computer-readable memory, which produces, to be included referring to Make the manufacture of device, the command device realize in one flow of flow chart or multiple flows and/or one square frame of block diagram or The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that counted Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented processing, so as in computer or The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in individual square frame or multiple square frames.
Although preferred embodiments of the present invention have been described, but those skilled in the art once know basic creation Property concept, then can make other change and modification to these embodiments.So appended claims be intended to be construed to include it is excellent Select embodiment and fall into having altered and changing for the scope of the invention.
Obviously, those skilled in the art can carry out various changes and modification without departing from this hair to the embodiment of the present invention The spirit and scope of bright embodiment.So, if these modifications and variations of the embodiment of the present invention belong to the claims in the present invention And its within the scope of equivalent technologies, then the present invention is also intended to comprising including these changes and modification.

Claims (18)

  1. A kind of 1. test case control method, applied in electronic equipment, it is characterised in that the display unit of the electronic equipment On show the control interface of case management system, the control interface includes outline editing area and use-case editing area, institute The directory information that outline editing area shows outline is stated, the use-case editing area shows the editing view of outline, described Include at least two editing interfaces of at least two test cases in editing view, at least two editing interface is according to institute State putting in order corresponding to directory information and show that methods described includes successively:
    Detection obtains the first operation for the control interface;
    Judge whether first operation meets the first preparatory condition;
    When the described first operation meets first preparatory condition, by the display content of the control interface by the first display Appearance is adjusted to the second display content;
    After detection obtains the second operation of the second preparatory condition of satisfaction, testing requirement circle of the second test case is jumped to Face, the testing requirement interface include demand directory area and test code region, and the demand directory area includes described the At least one index information corresponding at least one testing requirement of two test cases;
    Response is directed to the selection operation of the first index information at least one index information, first index information pair Answer the first testing requirement of second test case;
    The first test code corresponding to first index information is called in the test code region, to test described first Demand is tested.
  2. 2. the method as described in claim 1, it is characterised in that described to judge whether first operation meets the first default bar Part, it is specially:Judge whether first operation is the insertion operation that the first test case is inserted in the control interface;
    The display content by the control interface is adjusted to the second display content by the first display content, is specially:
    The first editing interface of first test case is inserted in the editing view.
  3. 3. the method as described in claim 1, it is characterised in that described to judge whether first operation meets the first default bar Part, it is specially:Judge whether first operation is that the first editing interface at least two editing interface is compiled The edit operation collected;
    The display content by the control interface is adjusted to the second display content by the first display content, is specially:
    The edit operation is responded, the parameter information of first editing interface is adjusted.
  4. 4. the method as described in claim 1, it is characterised in that described to judge whether first operation meets the first default bar Part, it is specially:Judge it is described first operation whether be the display content for adjust the use-case editing area first adjustment operate;
    The display content by the control interface is adjusted to the second display content by the first display content, is specially:
    It is sequentially adjusted in the display location of each editing interface at least two editing interface.
  5. 5. the method as described in claim 1, it is characterised in that described to judge whether first operation meets the first default bar Part, it is specially:Judge it is described first operation whether be adjust the first test case display location second adjustment operation;
    The display content by the control interface is adjusted to the second display content by the first display content, is specially:
    The first editing interface corresponding to first test case is adjusted to different from the first position by first position The second place.
  6. 6. the method as described in claim 1, it is characterised in that described to judge whether first operation meets the first default bar Part, it is specially:Judge whether first operation is the duplication operation for replicating the first test case;
    The display content by the control interface is adjusted to the second display content by the first display content, specifically includes:
    Threeth position corresponding with the described first operation adds the second editing interface in the editing view, and described second compiles Editing interface is identical with the parameter information of the first editing interface of first test case.
  7. 7. the method as described in claim 1, it is characterised in that described to call first index in the test code region The first test code, is specifically included corresponding to information:
    Determine multiple test codes corresponding to first index information;
    Based on the parameter information of second test case, the first test generation is filtered out from the multiple test code Code.
  8. 8. the method as described in claim 1-6 is any, it is characterised in that methods described also includes:
    At least two users are obtained the 3rd test case to be carried out testing corresponding at least two groups of test datas respectively;
    Based at least two groups of Test data generation aggregation test process;
    The result of the aggregation test process is analyzed, with the fault message at least two groups of test datas described in determination;
    Receive the modification operation that user is carried out based on the fault message to the 3rd test case;
    The 3rd test case after operation of modifying further is tested.
  9. 9. the method as described in claim 1-6 is any, it is characterised in that methods described also includes:
    Index value is set respectively to all test cases that the editing view is included, so that other systems can be by described Test case corresponding to index value calling.
  10. 10. a kind of electronic equipment, it is characterised in that the control of case management system is shown on the display unit of the electronic equipment Interface processed, the control interface include outline editing area and use-case editing area, and the outline editing area shows outline Directory information, the use-case editing area shows the editing view of outline, includes at least two in the editing view At least two editing interfaces of test case, at least two editing interface are suitable according to the arrangement corresponding to the directory information Sequence shows that the electronic equipment includes successively:
    Detection module, for detecting the first operation obtained for the control interface;
    Judge module, for judging whether first operation meets the first preparatory condition;
    Adjusting module, for described first operation meet first preparatory condition when, by the display of the control interface Hold and the second display content is adjusted to by the first display content;
    Jump module, after obtaining the second operation of the second preparatory condition of satisfaction in detection, jump to the second test case Testing requirement interface, the testing requirement interface include demand directory area and test code region, the demand directory area Domain includes at least one index information corresponding at least one testing requirement of second test case;
    Respond module, it is described for responding the selection operation for the first index information being directed at least one index information First index information corresponds to the first testing requirement of second test case;
    Calling module, for calling the first test code corresponding to first index information in the test code region, with First testing requirement is tested.
  11. 11. electronic equipment as claimed in claim 10, it is characterised in that the judge module, be specifically used for:Judge described Whether one operation is the insertion operation that the first test case is inserted in the control interface;
    The adjusting module, is specifically used for:
    The first editing interface of first test case is inserted in the editing view.
  12. 12. electronic equipment as claimed in claim 10, it is characterised in that the judge module, be specifically used for:Judge described Whether one operation is the edit operation for entering edlin to the first editing interface at least two editing interface;
    The adjusting module, is specifically used for:
    The edit operation is responded, the parameter information of first editing interface is adjusted.
  13. 13. electronic equipment as claimed in claim 10, it is characterised in that the judge module, be specifically used for:Judge described One operation whether be the display content for adjust the use-case editing area first adjustment operate;
    The adjusting module, is specifically used for:
    It is sequentially adjusted in the display location of each editing interface at least two editing interface.
  14. 14. electronic equipment as claimed in claim 10, it is characterised in that the judge module, be specifically used for:Judge described One operation whether be adjust the first test case display location second adjustment operation;
    The adjusting module, is specifically used for:
    The first editing interface corresponding to first test case is adjusted to different from the first position by first position The second place.
  15. 15. electronic equipment as claimed in claim 10, it is characterised in that the judge module, be specifically used for:Judge described Whether one operation is the duplication operation for replicating the first test case;
    The adjusting module, is specifically used for:
    Threeth position corresponding with the described first operation adds the second editing interface in the editing view, and described second compiles Editing interface is identical with the parameter information of the first editing interface of first test case.
  16. 16. electronic equipment as claimed in claim 10, it is characterised in that the calling module, specifically include:
    Determining unit, for determining multiple test codes corresponding to first index information;
    Screening unit, for the parameter information based on second test case, institute is filtered out from the multiple test code State the first test code.
  17. 17. the electronic equipment as described in claim 10-15 is any, it is characterised in that the electronic equipment also includes:
    Acquisition module, the 3rd test case is carried out testing corresponding at least two groups of surveys respectively for obtaining at least two users Try data;
    Generation module, for based at least two groups of Test data generation aggregation test process;
    Analysis module, for analyzing the result of the aggregation test process, with least two groups of test datas described in determination In fault message;
    Receiving module, the modification operation carried out for receiving user based on the fault message to the 3rd test case;
    Test module, for further being tested the 3rd test case after operation of modifying.
  18. 18. the electronic equipment as described in claim 10-15 is any, it is characterised in that the electronic equipment also includes:
    Setup module, for setting index value respectively to all test cases that the editing view is included, so that other are System can pass through test case corresponding to index value calling.
CN201510047542.9A 2015-01-29 2015-01-29 A kind of test case control method and electronic equipment Active CN104615536B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510047542.9A CN104615536B (en) 2015-01-29 2015-01-29 A kind of test case control method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510047542.9A CN104615536B (en) 2015-01-29 2015-01-29 A kind of test case control method and electronic equipment

Publications (2)

Publication Number Publication Date
CN104615536A CN104615536A (en) 2015-05-13
CN104615536B true CN104615536B (en) 2018-01-23

Family

ID=53149993

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510047542.9A Active CN104615536B (en) 2015-01-29 2015-01-29 A kind of test case control method and electronic equipment

Country Status (1)

Country Link
CN (1) CN104615536B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107239284A (en) * 2017-05-31 2017-10-10 河南思维轨道交通技术研究院有限公司 A kind of graphical intelligent test use-case and cycle tests preparation method
CN113361246A (en) * 2021-06-30 2021-09-07 北京高途云集教育科技有限公司 Handout production method and device, computer equipment and storage medium
CN115454828A (en) * 2022-08-25 2022-12-09 深圳市沃享科技有限公司 Online case testing method, equipment and storage medium

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101089826A (en) * 2006-06-12 2007-12-19 国际商业机器公司 Method and system for creating error tolerant and adaptive graphical user interface test automation

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8151248B1 (en) * 2007-10-31 2012-04-03 Sprint Communications Company L.P. Method and system for software defect management
CN101950269B (en) * 2010-08-30 2012-09-05 清华大学 Automatic test method for software members
CN102567193B (en) * 2010-12-09 2015-02-11 北京新媒传信科技有限公司 Method and system for converting test case to automated testing script

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101089826A (en) * 2006-06-12 2007-12-19 国际商业机器公司 Method and system for creating error tolerant and adaptive graphical user interface test automation

Also Published As

Publication number Publication date
CN104615536A (en) 2015-05-13

Similar Documents

Publication Publication Date Title
CN108021363B (en) Visual game logic editing method and system
White et al. Improving random GUI testing with image-based widget detection
Hilbert et al. Extracting usability information from user interface events
Kieras A guide to GOMS model usability evaluation using NGOMSL
Elberzhager et al. Reducing test effort: A systematic mapping study on existing approaches
Jones et al. A user-centred approach to functions in Excel
Ko et al. Finding causes of program output with the Java Whyline
US10185477B1 (en) Method and system for configuring automatic generation of narratives from data
US8402434B2 (en) Graphical user interface (GUI) script generation and documentation
US9946625B2 (en) Diagnostic tool and method for efficient software development
De Wit et al. Managing code clones using dynamic change tracking and resolution
CN107463500A (en) Adjustment method, medium, system and the computing device of test script
US10303751B1 (en) System and method for interaction coverage
EP2705441B1 (en) Automatic classification adjustment of recorded actions for automation script
CN102541740A (en) Android-based automatic test method for mobile phone notes
CN104615536B (en) A kind of test case control method and electronic equipment
CN108874649A (en) Generation method, device and its computer equipment of automatic test script
EP3786810A1 (en) Automatic generation of computing artifacts for data analysis
CN115080448B (en) Method and device for automatically detecting inaccessible path of software code
CN110990285B (en) UI (user interface) automatic testing method and device
Mao et al. User behavior pattern mining and reuse across similar Android apps
JP2000112784A (en) Program test support device and storage medium recording program test support program
CN114897296A (en) RPA flow labeling method, execution process playback method and storage medium
JP4675639B2 (en) Data processing system, method for displaying customization parameters of application program, and computer program product
US20130326466A1 (en) Human Readable Software Program Test Step

Legal Events

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