CN109840205A - Applied program testing method, device, readable storage medium storing program for executing and terminal device - Google Patents
Applied program testing method, device, readable storage medium storing program for executing and terminal device Download PDFInfo
- Publication number
- CN109840205A CN109840205A CN201811590928.4A CN201811590928A CN109840205A CN 109840205 A CN109840205 A CN 109840205A CN 201811590928 A CN201811590928 A CN 201811590928A CN 109840205 A CN109840205 A CN 109840205A
- Authority
- CN
- China
- Prior art keywords
- application
- test
- script
- testing
- application testing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000012360 testing method Methods 0.000 claims abstract description 333
- 238000013515 script Methods 0.000 claims abstract description 121
- 238000000034 method Methods 0.000 claims abstract description 91
- 230000008569 process Effects 0.000 claims abstract description 77
- 238000004088 simulation Methods 0.000 claims abstract description 46
- 238000010276 construction Methods 0.000 claims description 23
- 230000009471 action Effects 0.000 claims description 12
- 238000012163 sequencing technique Methods 0.000 claims description 4
- 238000001514 detection method Methods 0.000 claims 1
- 238000010998 test method Methods 0.000 claims 1
- 238000005516 engineering process Methods 0.000 abstract description 4
- 230000006870 function Effects 0.000 description 11
- 230000003993 interaction Effects 0.000 description 6
- 238000010586 diagram Methods 0.000 description 3
- 238000012544 monitoring process Methods 0.000 description 3
- 238000012545 processing Methods 0.000 description 3
- 230000004044 response Effects 0.000 description 2
- 238000012549 training Methods 0.000 description 2
- 230000001960 triggered effect Effects 0.000 description 2
- 241001269238 Data Species 0.000 description 1
- 208000033748 Device issues Diseases 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000010485 coping Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
Abstract
The invention belongs to field of computer technology more particularly to a kind of applied program testing method, device, computer readable storage medium and terminal devices.The method receives the Application testing instruction that user issues;Creation test process cluster corresponding with test terminal models list;The simulation test terminal of corresponding model is called in each test process respectively, and loads application program to be tested in each simulation test terminal;Application testing script corresponding with test script mark is searched in preset Application testing script bank;The application program is tested in each simulation test terminal according to the Application testing script.Through the embodiment of the present invention, multiple concurrent processes can be automatically created according to the instruction of user, it concurrent test is carried out to application program according to set test script in large number of simulation test terminal simultaneously, effectively reduces the time consumed by test process, significant increase testing efficiency.
Description
Technical field
The invention belongs to field of computer technology more particularly to a kind of applied program testing methods, device, computer-readable
Storage medium and terminal device.
Background technique
In order to guarantee that application program has good compatibility, before the formal commercialization of application program, generally require first
It is tested respectively on the terminal device of various models.In the terminal device model less epoch, typically by artificial
It is tested one by one, however, with the continuous development of technology, the model of terminal device is more and more in the market, applies journey every time
Sequence test needs to carry out respectively on hundreds of, even thousands of a terminal devices easily, will be disappeared using the method for manual testing
The a large amount of time is consumed, testing efficiency is extremely low.
Summary of the invention
In view of this, the embodiment of the invention provides a kind of applied program testing method, device, computer-readable storage mediums
Matter and terminal device, to solve to test application program on large number of terminal device using the method for manual testing
When consume a large amount of time, the extremely low problem of testing efficiency.
The first aspect of the embodiment of the present invention provides a kind of applied program testing method, may include:
The Application testing instruction that user issues is received, includes that test script identifies in the Application testing instruction
And terminal models list is tested, it include more than one test terminal models in the test terminal models list;
Create test process cluster corresponding with the test terminal models list, wherein in the test process cluster
Each test process and it is described test terminal models list in each test terminal models correspond;
The simulation test terminal of corresponding model is called in each test process respectively, and in each simulation test terminal
Load application program to be tested;
Application testing corresponding with test script mark is searched in preset Application testing script bank
Script;
The application program is tested in each simulation test terminal according to the Application testing script.
The second aspect of the embodiment of the present invention provides a kind of Application testing device, may include:
Command reception module is tested, the Application testing instruction issued for receiving user, the Application testing
Include that test script identifies and test terminal models list in instruction, includes more than one in the test terminal models list
Test terminal models;
Test process creation module, for creating test process cluster corresponding with the test terminal models list,
In, each test terminal models in each test process and the test terminal models list in the test process cluster
It corresponds;
Terminal calling module is tested, for the simulation test terminal of corresponding model to be called in each test process respectively,
And application program to be tested is loaded in each simulation test terminal;
Test script searching module, for being searched and the test script mark in preset Application testing script bank
Know corresponding Application testing script;
Application testing module, for according to the Application testing script in each simulation test terminal to institute
Application program is stated to be tested.
The third aspect of the embodiment of the present invention provides a kind of computer readable storage medium, the computer-readable storage
Media storage has computer-readable instruction, and the computer-readable instruction realizes following steps when being executed by processor:
The Application testing instruction that user issues is received, includes that test script identifies in the Application testing instruction
And terminal models list is tested, it include more than one test terminal models in the test terminal models list;
Create test process cluster corresponding with the test terminal models list, wherein in the test process cluster
Each test process and it is described test terminal models list in each test terminal models correspond;
The simulation test terminal of corresponding model is called in each test process respectively, and in each simulation test terminal
Load application program to be tested;
Application testing corresponding with test script mark is searched in preset Application testing script bank
Script;
The application program is tested in each simulation test terminal according to the Application testing script.
The fourth aspect of the embodiment of the present invention provides a kind of terminal device, including memory, processor and is stored in
In the memory and the computer-readable instruction that can run on the processor, the processor executes the computer can
Following steps are realized when reading instruction:
The Application testing instruction that user issues is received, includes that test script identifies in the Application testing instruction
And terminal models list is tested, it include more than one test terminal models in the test terminal models list;
Create test process cluster corresponding with the test terminal models list, wherein in the test process cluster
Each test process and it is described test terminal models list in each test terminal models correspond;
The simulation test terminal of corresponding model is called in each test process respectively, and in each simulation test terminal
Load application program to be tested;
Application testing corresponding with test script mark is searched in preset Application testing script bank
Script;
The application program is tested in each simulation test terminal according to the Application testing script.
Existing beneficial effect is the embodiment of the present invention compared with prior art: the embodiment of the present invention is in the case where receiving user
After the Application testing instruction of hair, test process cluster corresponding with test terminal models list is created first, wherein institute
The each test terminal models stated in each test process and test the terminal models list in test process cluster correspond,
Then the simulation test terminal of corresponding model is called in each test process respectively, and is loaded in each simulation test terminal
Application program to be tested is then searched in preset Application testing script bank corresponding with test script mark
Application testing script, according to the Application testing script in each simulation test terminal to the application program into
Row test.Through the embodiment of the present invention, multiple concurrent processes can be automatically created according to the instruction of user, while large number of
Simulation test terminal on according to set test script to application program carry out concurrent test, effectively reduce test process institute
Time of consumption, significant increase testing efficiency.
Detailed description of the invention
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to embodiment or description of the prior art
Needed in attached drawing be briefly described, it should be apparent that, the accompanying drawings in the following description is only of the invention some
Embodiment for those of ordinary skill in the art without any creative labor, can also be according to these
Attached drawing obtains other attached drawings.
Fig. 1 is the schematic flow diagram of the generating process of Application testing script;
Fig. 2 is a kind of one embodiment flow chart of applied program testing method in the embodiment of the present invention;
Fig. 3 is a kind of one embodiment structure chart of Application testing device in the embodiment of the present invention;
Fig. 4 is a kind of schematic block diagram of terminal device in the embodiment of the present invention.
Specific embodiment
In order to make the invention's purpose, features and advantages of the invention more obvious and easy to understand, below in conjunction with the present invention
Attached drawing in embodiment, technical scheme in the embodiment of the invention is clearly and completely described, it is clear that disclosed below
Embodiment be only a part of the embodiment of the present invention, and not all embodiment.Based on the embodiments of the present invention, this field
Those of ordinary skill's all other embodiment obtained without making creative work, belongs to protection of the present invention
Range.
In the present embodiment, the dismantling of the testing process of application program will can be grasped at multiple single application programs in advance
It acts, logic will be executed and be encapsulated in inside each application program operational controls, be presented to the user with patterned way.User is not
Complicated script must be write, but is selected by simple control and a small amount of operation information configuration, so that it may which completion is complete to one
The script edit of whole Application testing process works, and executes the Application testing script, can be realized to application program
The simulation of test process.
As shown in Figure 1, the generating process of Application testing script may include:
Step S101, the Application testing script edit instruction that user issues is received, preset application program is operated
Each application program operational controls in widget library show user.
In the present embodiment, the application program that Application testing script edit is carried out for user is provided, user can be with
Writing for Application testing script is carried out on the terminal device for be mounted with the application program.
When needing to carry out Application testing script edit, user can pass through specified human-computer interaction interface (Human
Machine Interaction, HMI) to terminal device the instruction of Application testing script edit is issued, terminal device receiving
To after the instruction, each application program operational controls in preset application program operational controls library are showed into user, for
User's selection.
Wherein, each application program operational controls both correspond to an application program operational motion, and control is by inside programming
Logic is packaged, and provides a small amount of parameter only so that user carries out operation information configuration, use is presented in a manner of simple, intuitive
Family operation.
Application program operational controls in the application program operational controls library include but is not limited to combobox selection control, son
Element obtains control, element coordinate obtains control, mouse-click control, double click control, text-entry control, Reading text
Control, check box selection control, default response control etc..
Wherein, operation of the combobox selection control for analog subscriber selection combobox, user is in multipad
Combobox element is selected, the display tree construction based on desktop of element is obtained, input selects content, when script operation, the control
Part navigates to the drop-down entry for the combobox chosen according to the display tree construction and selection content of element;Daughter element obtains control
For obtaining daughter element object in element, user selects element in multipad, and the daughter element for obtaining control is based on table
The display tree construction in face, the display tree construction set of daughter element is as output parameter, and when script is run, the control is according to daughter element
Display tree construction obtain daughter element;Element coordinate obtains control for obtaining the element coordinate chosen, and user is in desktop application
Interface selects element, obtains the display tree construction based on desktop of element, selects the position of element, is exported and is sat according to element position
Mark, element position have " upper left ", " lower-left ", " upper right ", " bottom right ", " left ", " in the right side ", " in upper ", " in lower " and " center "
Nine points can choose.Mouse-click control is used for the operation of analog subscriber a mouse click, and user clicks at desktop application interface
Mouse selects element, obtains display tree construction of the element based on desktop, and when Run Script, which passes through the display tree of element
Structures capture interface element executes a mouse click operation;Double click control is used for the operation of analog subscriber double click, user
Mouse is clicked at desktop application interface and selects element, obtains display tree construction of the element based on desktop, when Run Script, the control
Part captures interface element by the display tree construction of element, executes double click operation;Text-entry control is used for analog subscriber
Text maninulation is inputted in the element chosen, user selects the element of input text at desktop application interface, obtains the base of element
In the display tree construction of desktop, when Run Script, which obtains interface element according to the display tree construction of element, in element
The content that interior input user specifies;Reading text control is for obtaining the content text for choosing element, and user is in desktop application circle
Element is chosen in face, obtains the display tree construction based on desktop of element, and when Run Script, the control is aobvious according to the element of acquisition
Show tree construction, reads element text information;Check box selects control for analog subscriber selection check box operation, and user is in desktop
Application interface chooses check box element, obtains display tree construction of the element based on desktop, simultaneous selection elementary state, elementary state
Including " choosing ", " cancellation " two states, when script operation, which chooses multiple according to the display tree construction of the element of acquisition
Frame is selected, and check box selected state is arranged according to the state selected in advance;Default response control selects element for analog subscriber
And selected element is responded automatically, user obtains the aobvious based on desktop of element in the element of interface selection desktop application
Show tree construction, when script operation, program navigates to the element of selection according to the display tree construction of element, and is rung accordingly
It should operate.
Step S102, the application program operational controls selection instruction that user issues is received.
It include that control identifies in the application program operational controls selection instruction.
Each application program operation control that user can be shown by the human-computer interaction interface in the terminal device
It is selected in part, Xiang Suoshu terminal device issues the application program operational controls selection instruction that carry control mark.
Step S103, object run control corresponding with control mark is selected in application program operational controls library
Part, and obtain operation information corresponding with the object run control.
The terminal device can extract it after receiving the application program operational controls selection instruction that user issues
In control mark, corresponding with control mark operational controls are selected in application program operational controls library, namely
The object run control, and obtain operation information corresponding with the object run control.
During obtaining operation information corresponding with the object run control, monitoring is the terminal device first
It is no to receive user by selecting on the human-computer interaction interface by clicking the application elements that the corresponding button is issued
Instruction, if receiving the application elements selection instruction that user issues, in the application by process as follows
Determine window handle corresponding with the object run control and courses of action:
Firstly, it is signified to obtain mouse pointer after detecting that mouse pointer moves for monitoring mouse pointer moving event
To window handle.
In the present embodiment, mouse pointer moving event can be monitored by adding Onmousemove function to desktop,
When mouse pointer occurs mobile, Onmousemove function is triggered, and is obtained at this time by WindowFromPoint function
The window handle (including window, button, text box etc.) and process title of top-level windows pointed by mouse pointer.By current
The window handle of top-level windows pointed by mouse pointer obtains handle relative to the coordinate of computer screen and shows size,
And it is drawn on the screen with the consistent red rectangle frame of handle, the handle selected for identity user current mouse.
Wherein, Onmousemove and WindowFromPoint is hypertext markup language (Hyper Text Mark-
Up Language, HTML) in system function, Onmousemove function can be triggered when mouse pointer is mobile,
The function of WindowFromPoint function is the handle for obtaining the window comprising specified point.
Then, father's handles at different levels of the window handle are successively traversed, and according to father's handles at different levels of the window handle
Construct the courses of action of the window handle.
(press left mouse button) after user confirms the handle of selection, obtain current handle X1 FrameworkId,
ControlTypeId, ClassName, AutomationId, Name etc. identify key message and his father of handle uniqueness
Handle X2 and its position Index in identical fraternal handle, then obtain again handle X2 FrameworkId,
ControlTypeId, ClassName, AutomationId, Name etc. identify key message and his father of handle uniqueness
Handle X3 and its position in identical fraternal handle.First ancestor " desktop " of this process until getting all handles is recycled, finally
UI structure tree namely the courses of action of the handle of mouse direction based on " desktop " are obtained, as follows: " [" "
Process"":""calc"",""FrameworkId"":"""",""ControlTypeId"":""50011"",""
ClassName " ": " " " ", " " AutomationId " ": " " " ", " " Name " ": " " checks (V) " ", " " IsEnabled " ": " "
1"",""Index"":""""},{""Process"":""calc"",""FrameworkId"":"""",""
ControlTypeId"":""50010"",""ClassName"":"""",""AutomationId"":"""",""
Name " ": " " application program " ", " " IsEnabled " ": " " 1 " ", " " Index " ": " " " " }, { " " Process " ": " "
calc"",""FrameworkId"":""Win32"",""ControlTypeId"":""50032"",""ClassName"":""
CalcFrame " ", " " AutomationId " ": " " " ", " " Name " ": " " calculator " ", " " IsEnabled " ": " " 1 " ", " "
Index"":""""}]"
It should be noted that according to FrameworkId, ControlTypeId, ClassName, AutomationId,
During Name determines unique handle, if there are identical two sub- handles in father's handle, distinguished according to Index.
UI structure tree chooses clause's handle for starting with mouse, is to terminate with final " desktop " handle.
Determine in the application by the above process window handle corresponding with the object run control and
After courses of action, then user can be further obtained to the operation content of the window handle, and by the window handle, operation
Path and the operation content are added into operation information corresponding with the object run control.
Wherein, user is corresponding with current operational controls to the operation content of window handle, i.e., for different
Its operation content of operational controls is typically also different.By taking text-entry control as an example, concrete operations content is in window
The text that input user issues in element corresponding to handle.
Step S104, the object run control and the operation information are configured to an Application testing entry.
Wherein, each Application testing entry both corresponds to an application program operational motion, and each application program is surveyed
Strip mesh includes application program operational controls and operation information.
Step S105, it receives the Application testing script that user issues and generates instruction, by each Application testing item
Mesh generates Application testing script according to the sequencing of construction.
After the construction for completing each Application testing entry, user can be by the human-computer interaction interface to institute
It states terminal device and issues Application testing script and generate instruction, the terminal device, can will be each after receiving the instruction
A Application testing entry generates Application testing script as shown in the table according to the sequencing of construction:
Application testing entry | Application program operational controls | Operation information |
Tested entries 1 | Operational controls XX | Operation information XX |
Tested entries 2 | Operational controls XX | Operation information XX |
Tested entries 3 | Operational controls XX | Operation information XX |
…… | …… | …… |
After generating the Application testing script, the terminal device can be added it in the form of script file
Enter in Application testing script bank, so that subsequent user is called.
The above is only the generating process of an Application testing script, in practical applications, can be as procedure described above
Corresponding Application testing script is generated respectively for multiple and different Application testing processes, and is added into the application
In program test script bank, to meet the needs of user is under different scenes.
As shown in Fig. 2, can pass through in the embodiment of the present invention after Application testing script bank building is completed
Following steps carry out the simulation process of executing application test:
Step S201, the Application testing instruction that user issues is received.
It include that test script identifies and test terminal models list in the Application testing instruction, the test is eventually
Holding includes more than one test terminal models in model list.When user needs to be implemented scheduled Application testing process
When, Application testing instruction can be issued to the terminal device by the human-computer interaction interface.Journey is applied due to described
Numerous Application testing scripts is contained in sequence test script library, for the ease of difference, passes through test in the present embodiment
Script identifies uniquely to be identified to each Application testing script, and each Application testing script is corresponding unique
Test script mark, carry test script mark in the instruction of Application testing that user issues.
Step S202, test process cluster corresponding with the test terminal models list is created.
Wherein, each survey in each test process in the test process cluster and the test terminal models list
Terminal models are tried to correspond.
Step S203, the simulation test terminal of corresponding model is called in each test process respectively, and in each simulation
Application program to be tested is loaded in test terminal.
It should be noted that these simulation test terminals are the simulation terminals fictionalized in corresponding test process, and
Non- actual terminal device, these simulation test terminals can simulate terminal device for the reaction of various operations, to sentence
It is disconnected go out application program whether normal operation.
Step S204, application program corresponding with test script mark is searched in Application testing script bank to survey
Training sheet.
The terminal device can extract after receiving the Application testing instruction that user issues from the instruction
Then test script mark is searched corresponding with test script mark using journey in the Application testing script bank
Sequence test script.
Step S205, according to the Application testing script in each simulation test terminal to the application program into
Row test.
It is then successively held firstly, being successively read each Application testing entry from the Application testing script
Each Application testing entry in the row Application testing script, to realize the mould to Application testing process
It is quasi-.
Wherein, in the implementation procedure of each Application testing entry, the application program operational controls is called to press
According to the operation information executing application operation simulation.
Firstly, based on the courses of action in the operation information, from starting name handle " desktop " according to mark handle uniqueness
Key message (FrameworkId, ControlTypeId, ClassName, AutomationId, Name, identical fraternal handle
In position) obtain its corresponding clause's handle.It recycles this process and successively finds final target handle namely script edit downwards
The handle for the top-level windows that stage mouse is directed toward, then call corresponding event interface execute corresponding operation (such as mouse-click,
Text input, Reading text, combobox selection etc.).
Wherein, during searching clause's handle, calling CreatePropertyCondition first creates search criterion
Array, such as UIA_NameProperty, UIA_ClassNameProperty (corresponding Name, ClassName) etc., recall
UI structure tree character string is passed to FindAll interface by the FindAll interface of UIAutomationElement, can be with
All UIAutomationElement for meeting these conditions are filtered out, it is (identical according to Index if returned the result greater than 1
Position in fraternal handle) filter out target handle.
After finding the target window handle finally to be operated, then the application program operational controls can be called to press
The target window handle is operated according to the operation content in the operation information.
In conclusion the embodiment of the present invention creates first after receiving the Application testing instruction that user issues
With the corresponding test process cluster of test terminal models list, wherein each test process in the test process cluster with
The each test terminal models tested in terminal models list correspond, and then call and correspond in each test process respectively
The simulation test terminal of model, and application program to be tested is loaded in each simulation test terminal, then answered preset
With Application testing script corresponding with test script mark is searched in program test script bank, journey is applied according to described
Sequence test script tests the application program in each simulation test terminal.It through the embodiment of the present invention, can be by
Instruction according to user automatically creates multiple concurrent processes, while according to set test in large number of simulation test terminal
Script carries out concurrent test to application program, effectively reduce the time consumed by test process, significant increase testing efficiency.
It should be understood that the size of the serial number of each step is not meant that the order of the execution order in above-described embodiment, each process
Execution sequence should be determined by its function and internal logic, the implementation process without coping with the embodiment of the present invention constitutes any limit
It is fixed.
Corresponding to a kind of applied program testing method described in foregoing embodiments, Fig. 3 shows offer of the embodiment of the present invention
A kind of Application testing device one embodiment structure chart.
In the present embodiment, a kind of Application testing device may include:
Command reception module 301 is tested, the Application testing instruction issued for receiving user, the application program is surveyed
Include that test script identifies and tests terminal models list in examination instruction, in the test terminal models list including one with
On test terminal models;
Test process creation module 302, for creating test process cluster corresponding with the test terminal models list,
Wherein, each test terminal type in each test process in the test process cluster and the test terminal models list
Number correspond;
Terminal calling module 303 is tested, for calling the simulation test of corresponding model whole in each test process respectively
End, and application program to be tested is loaded in each simulation test terminal;
Test script searching module 304, for being searched and the test foot in preset Application testing script bank
The corresponding Application testing script of this mark;
Application testing module 305 is used for according to the Application testing script in each simulation test terminal
The application program is tested.
Further, the Application testing module may include:
Tested entries read module, for being successively read each Application testing from the Application testing script
Entry, wherein each Application testing entry both corresponds to an application program operational motion, each Application testing item
Mesh includes application program operational controls and operation information;
Tested entries execution module, for successively executing each Application testing in the Application testing script
Entry, to realize the simulation to Application testing process, wherein in the implementation procedure of each Application testing entry,
The application program operational controls are called to test according to the operation information executing application.
Further, the Application testing device can also include::
Operational controls display module, the Application testing script edit instruction issued for receiving user, will be preset
Each application program operational controls in application program operational controls library show user;
Control selection instruction receiving module, the application program operational controls selection instruction issued for receiving user are described
It include that control identifies in application program operational controls selection instruction;
Object run control selecting module, for the selection in application program operational controls library and control mark
Corresponding object run control;
Operation information acquisition module, for obtaining operation information corresponding with the object run control;
Tested entries constructing module, for the object run control and the operation information to be configured to one using journey
Sequence tested entries;
Test script generation module generates instruction for receiving the Application testing script that user issues, answers each
Application testing script is generated according to the sequencing of construction with program test entry, and the application program of generation is surveyed
Training is originally added into the Application testing script bank.
Further, the operation information acquisition module may include:
Window handle determination unit, the application elements selection instruction issued for receiving user, in the application
Determine window handle corresponding with the object run control and courses of action;
Operation content acquiring unit, for obtaining user to the operation content of the window handle, and by the window sentence
Handle, courses of action and the operation content are added into operation information corresponding with the object run control.
Further, the window handle determination unit may include:
Window handle obtains subelement, for monitoring mouse pointer moving event, when detecting that mouse pointer moves
Afterwards, the window handle of top-level windows pointed by mouse pointer is obtained;
Courses of action construct subelement, for successively traversing father's handles at different levels of the window handle, and according to the window
Father's handles at different levels of mouth handle construct the courses of action of the window handle.
Further, the operation entries execution module may include:
Target window handle searching unit, for according to the courses of action in the operation information in application window
Gradually search target window handle corresponding with the application program operational controls;
Operation execution unit, for calling the application program operational controls according to the operation content in the operation information
The target window handle is operated.
It is apparent to those skilled in the art that for convenience and simplicity of description, the device of foregoing description,
The specific work process of module and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In the above-described embodiments, it all emphasizes particularly on different fields to the description of each embodiment, is not described in detail or remembers in some embodiment
The part of load may refer to the associated description of other embodiments.
The schematic block diagram that Fig. 4 shows a kind of terminal device provided in an embodiment of the present invention is only shown for ease of description
Part related to the embodiment of the present invention.
In the present embodiment, the terminal device 4 can be desktop PC, notebook, palm PC and cloud clothes
Business device etc. calculates equipment.The terminal device 4 can include: processor 40, memory 41 and be stored in the memory 41 simultaneously
The computer-readable instruction 42 that can be run on the processor 40, such as execute the calculating of above-mentioned applied program testing method
Machine readable instruction.The processor 40 realizes above-mentioned each applied program testing method when executing the computer-readable instruction 42
Step in embodiment, such as step S201 to S205 shown in Fig. 2.Alternatively, the processor 40 execute the computer can
The function of each module/unit in above-mentioned each Installation practice, such as the function of module 301 to 305 shown in Fig. 3 are realized when reading instruction 42
Energy.
Illustratively, the computer-readable instruction 42 can be divided into one or more module/units, one
Or multiple module/units are stored in the memory 41, and are executed by the processor 40, to complete the present invention.Institute
Stating one or more module/units can be the series of computation machine readable instruction section that can complete specific function, the instruction segment
For describing implementation procedure of the computer-readable instruction 42 in the terminal device 4.
The processor 40 can be central processing unit (Central Processing Unit, CPU), can also be
Other general processors, digital signal processor (Digital Signal Processor, DSP), specific integrated circuit
(Application Specific Integrated Circuit, ASIC), field programmable gate array (Field-
Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic,
Discrete hardware components etc..General processor can be microprocessor or the processor is also possible to any conventional processor
Deng.
The memory 41 can be the internal storage unit of the terminal device 4, such as the hard disk or interior of terminal device 4
It deposits.The memory 41 is also possible to the External memory equipment of the terminal device 4, such as be equipped on the terminal device 4
Plug-in type hard disk, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) card dodge
Deposit card (Flash Card) etc..Further, the memory 41 can also both include the storage inside list of the terminal device 4
Member also includes External memory equipment.The memory 41 is for storing the computer-readable instruction and the terminal device 4
Required other instruction and datas.The memory 41 can be also used for temporarily storing the number that has exported or will export
According to.
The functional units in various embodiments of the present invention may be integrated into one processing unit, is also possible to each
Unit physically exists alone, and can also be integrated in one unit with two or more units.Above-mentioned integrated unit both may be used
To use formal implementation of hardware, can also realize in the form of software functional units.
If the integrated unit is realized in the form of SFU software functional unit and sells or use as independent product
When, it can store in a computer readable storage medium.Based on this understanding, technical solution of the present invention substantially or
Person says that all or part of the part that contributes to existing technology or the technical solution can body in the form of software products
Reveal and, which is stored in a storage medium, including several computer-readable instructions are used so that one
Platform computer equipment (can be personal computer, server or the network equipment etc.) executes described in each embodiment of the present invention
The all or part of the steps of method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (ROM, Read-
Only Memory), random access memory (RAM, Random Access Memory), magnetic or disk etc. are various can be with
Store the medium of computer-readable instruction.
Embodiment described above is merely illustrative of the technical solution of the present invention, rather than its limitations;Although referring to aforementioned reality
Applying example, invention is explained in detail, those skilled in the art should understand that: it still can be to aforementioned each
Technical solution documented by embodiment is modified or equivalent replacement of some of the technical features;And these are modified
Or replacement, the spirit and scope for technical solution of various embodiments of the present invention that it does not separate the essence of the corresponding technical solution.
Claims (10)
1. a kind of applied program testing method characterized by comprising
Receive the Application testing instruction that user issues, include in the Application testing instruction test script mark and
Terminal models list is tested, includes more than one test terminal models in the test terminal models list;
Create test process cluster corresponding with the test terminal models list, wherein each in the test process cluster
Each test terminal models in a test process and the test terminal models list correspond;
The simulation test terminal of corresponding model is called in each test process respectively, and is loaded in each simulation test terminal
Application program to be tested;
Application testing script corresponding with test script mark is searched in preset Application testing script bank;
The application program is tested in each simulation test terminal according to the Application testing script.
2. applied program testing method according to claim 1, which is characterized in that described according to the Application testing
Script carries out test to the application program in each simulation test terminal
Each Application testing entry is successively read from the Application testing script, wherein each application program is surveyed
Strip mesh both corresponds to an application program operational motion, and each Application testing entry includes application program operational controls
And operation information;
Each Application testing entry in the Application testing script is executed, successively to realize to Application testing
The simulation of process, wherein in the implementation procedure of each Application testing entry, call the application program operational controls
It is tested according to the operation information executing application.
3. applied program testing method according to claim 1, which is characterized in that in the application program that reception user issues
Before test instruction, further includes:
The Application testing script edit instruction that user issues is received, it will be each in preset application program operational controls library
Application program operational controls show user;
The application program operational controls selection instruction that user issues is received, includes in the application program operational controls selection instruction
Control mark;
Object run control corresponding with control mark, and acquisition and institute are selected in application program operational controls library
State the corresponding operation information of object run control;
The object run control and the operation information are configured to an Application testing entry;
It receives the Application testing script that user issues and generates instruction, by each Application testing entry according to the elder generation of construction
After be sequentially generated Application testing script, and the Application testing script of generation is added into the application program and is surveyed
Try script bank.
4. applied program testing method according to claim 3, which is characterized in that the acquisition and the object run control
The corresponding operation information of part includes:
The application elements selection instruction that user issues is received, determination is corresponding with the object run control in the application
Window handle and courses of action;
User is obtained to the operation content of the window handle, and by the window handle, courses of action and the operation content
It is added into operation information corresponding with the object run control.
5. applied program testing method according to claim 4, which is characterized in that the determining and institute in the application
It states the corresponding window handle of target detection control and test path includes:
Mouse pointer moving event is monitored, after detecting that mouse pointer moves, obtains window pointed by mouse pointer
Handle;
Father's handles at different levels of the window handle are successively traversed, and construct the window according to father's handles at different levels of the window handle
The test path of mouth handle.
6. a kind of Application testing device characterized by comprising
Command reception module is tested, the Application testing instruction issued for receiving user, the Application testing instruction
In include that test script identifies and tests terminal models list, including more than one survey in the test terminal models list
Try terminal models;
Test process creation module, for creating test process cluster corresponding with the test terminal models list, wherein institute
State each test terminal models in each test process in test process cluster and the test terminal models list one by one
It is corresponding;
Terminal calling module is tested, for calling the simulation test terminal of corresponding model in each test process respectively, and
Application program to be tested is loaded in each simulation test terminal;
Test script searching module, for being searched in preset Application testing script bank and test script mark pair
The Application testing script answered;
Application testing module, for being answered in each simulation test terminal described according to the Application testing script
It is tested with program.
7. Application testing device according to claim 6, which is characterized in that the Application testing module packet
It includes:
Tested entries read module, for being successively read each Application testing item from the Application testing script
Mesh, wherein each Application testing entry both corresponds to an application program operational motion, each Application testing entry
It include application program operational controls and operation information;
Tested entries execution module, for successively executing each Application testing item in the Application testing script
Mesh, to realize the simulation to Application testing process, wherein in the implementation procedure of each Application testing entry,
The application program operational controls are called to test according to the operation information executing application.
8. applied program testing method according to claim 6, which is characterized in that further include:
Operational controls display module, the Application testing script edit instruction issued for receiving user, by preset application
Each application program operational controls in procedure operation widget library show user;
Control selection instruction receiving module, the application program operational controls selection instruction issued for receiving user, the application
It include that control identifies in procedure operation control selection instruction;
Object run control selecting module, it is corresponding with control mark for being selected in application program operational controls library
Object run control;
Operation information acquisition module, for obtaining operation information corresponding with the object run control;
Tested entries constructing module is surveyed for the object run control and the operation information to be configured to an application program
Strip mesh;
Test script generation module generates instruction for receiving the Application testing script that user issues, applies journey for each
Sequence tested entries generate Application testing script according to the sequencing of construction, and by the Application testing foot of generation
Originally it is added into the Application testing script bank.
9. a kind of computer readable storage medium, the computer-readable recording medium storage has computer-readable instruction, special
Sign is, the application journey as described in any one of claims 1 to 5 is realized when the computer-readable instruction is executed by processor
The step of sequence test method.
10. a kind of terminal device, including memory, processor and storage are in the memory and can be on the processor
The computer-readable instruction of operation, which is characterized in that the processor realizes such as right when executing the computer-readable instruction
It is required that the step of applied program testing method described in any one of 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811590928.4A CN109840205A (en) | 2018-12-20 | 2018-12-20 | Applied program testing method, device, readable storage medium storing program for executing and terminal device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811590928.4A CN109840205A (en) | 2018-12-20 | 2018-12-20 | Applied program testing method, device, readable storage medium storing program for executing and terminal device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109840205A true CN109840205A (en) | 2019-06-04 |
Family
ID=66883360
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811590928.4A Pending CN109840205A (en) | 2018-12-20 | 2018-12-20 | Applied program testing method, device, readable storage medium storing program for executing and terminal device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109840205A (en) |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110502414A (en) * | 2019-08-20 | 2019-11-26 | Oppo广东移动通信有限公司 | Terminal device performance test methods, device, terminal device and storage medium |
CN110618944A (en) * | 2019-09-20 | 2019-12-27 | 百度在线网络技术(北京)有限公司 | Device simulation method, device, electronic device and storage medium |
CN110908899A (en) * | 2019-11-08 | 2020-03-24 | 北京奇艺世纪科技有限公司 | Application program debugging method, mobile terminal and computer readable storage medium |
CN111061630A (en) * | 2019-11-26 | 2020-04-24 | 歌尔股份有限公司 | Product debugging method, debugging device and readable storage medium |
CN111817916A (en) * | 2020-07-02 | 2020-10-23 | 浙江同花顺智能科技有限公司 | Test method, device, equipment and storage medium based on mobile terminal cluster |
CN112214389A (en) * | 2019-07-09 | 2021-01-12 | 腾讯科技(深圳)有限公司 | Public testing method, device, terminal and storage medium |
CN112817811A (en) * | 2020-12-31 | 2021-05-18 | 深圳市联影高端医疗装备创新研究院 | Method, device, equipment and storage medium for predicting scanning failure rate |
CN113010416A (en) * | 2021-02-26 | 2021-06-22 | 中国工商银行股份有限公司 | Bank counter transaction automatic testing method and device |
CN113220569A (en) * | 2021-05-10 | 2021-08-06 | 中金金融认证中心有限公司 | Multi-process-based iOS compatibility automatic testing method and device |
CN116756054A (en) * | 2023-08-23 | 2023-09-15 | 北京集度科技有限公司 | Test method, test device, electronic equipment and storage medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101013977A (en) * | 2007-02-08 | 2007-08-08 | 华为技术有限公司 | Network testing method and system |
US20120260231A1 (en) * | 2011-04-07 | 2012-10-11 | Fujitsu Limited | Code conversion method, apparatus, storage medium and request remaining time response method |
CN104679659A (en) * | 2015-03-24 | 2015-06-03 | 小米科技有限责任公司 | Testing method and testing device of application program as well as electronic equipment |
US20160004625A1 (en) * | 2014-07-07 | 2016-01-07 | Unisys Corporation | Method of executing test scripts based on runtime test selection |
US20170370988A1 (en) * | 2016-06-28 | 2017-12-28 | International Business Machines Corporation | Burn-in testing of individually personalized semiconductor device configuration |
-
2018
- 2018-12-20 CN CN201811590928.4A patent/CN109840205A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101013977A (en) * | 2007-02-08 | 2007-08-08 | 华为技术有限公司 | Network testing method and system |
US20120260231A1 (en) * | 2011-04-07 | 2012-10-11 | Fujitsu Limited | Code conversion method, apparatus, storage medium and request remaining time response method |
US20160004625A1 (en) * | 2014-07-07 | 2016-01-07 | Unisys Corporation | Method of executing test scripts based on runtime test selection |
CN104679659A (en) * | 2015-03-24 | 2015-06-03 | 小米科技有限责任公司 | Testing method and testing device of application program as well as electronic equipment |
US20170370988A1 (en) * | 2016-06-28 | 2017-12-28 | International Business Machines Corporation | Burn-in testing of individually personalized semiconductor device configuration |
Cited By (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112214389B (en) * | 2019-07-09 | 2023-09-26 | 腾讯科技(深圳)有限公司 | Crowd measurement method, device, terminal and storage medium |
CN112214389A (en) * | 2019-07-09 | 2021-01-12 | 腾讯科技(深圳)有限公司 | Public testing method, device, terminal and storage medium |
CN110502414A (en) * | 2019-08-20 | 2019-11-26 | Oppo广东移动通信有限公司 | Terminal device performance test methods, device, terminal device and storage medium |
CN110502414B (en) * | 2019-08-20 | 2023-08-29 | Oppo广东移动通信有限公司 | Terminal equipment performance test method and device, terminal equipment and storage medium |
CN110618944A (en) * | 2019-09-20 | 2019-12-27 | 百度在线网络技术(北京)有限公司 | Device simulation method, device, electronic device and storage medium |
CN110908899A (en) * | 2019-11-08 | 2020-03-24 | 北京奇艺世纪科技有限公司 | Application program debugging method, mobile terminal and computer readable storage medium |
CN111061630A (en) * | 2019-11-26 | 2020-04-24 | 歌尔股份有限公司 | Product debugging method, debugging device and readable storage medium |
CN111817916B (en) * | 2020-07-02 | 2022-06-03 | 浙江同花顺智能科技有限公司 | Test method, device, equipment and storage medium based on mobile terminal cluster |
CN111817916A (en) * | 2020-07-02 | 2020-10-23 | 浙江同花顺智能科技有限公司 | Test method, device, equipment and storage medium based on mobile terminal cluster |
CN112817811A (en) * | 2020-12-31 | 2021-05-18 | 深圳市联影高端医疗装备创新研究院 | Method, device, equipment and storage medium for predicting scanning failure rate |
CN113010416A (en) * | 2021-02-26 | 2021-06-22 | 中国工商银行股份有限公司 | Bank counter transaction automatic testing method and device |
CN113220569A (en) * | 2021-05-10 | 2021-08-06 | 中金金融认证中心有限公司 | Multi-process-based iOS compatibility automatic testing method and device |
CN116756054A (en) * | 2023-08-23 | 2023-09-15 | 北京集度科技有限公司 | Test method, test device, electronic equipment and storage medium |
CN116756054B (en) * | 2023-08-23 | 2023-10-24 | 北京集度科技有限公司 | Test method, test device, electronic equipment and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109840205A (en) | Applied program testing method, device, readable storage medium storing program for executing and terminal device | |
US8291329B2 (en) | Automatically merging graphical programs | |
CN103984626B (en) | A kind of method and device for generating test case script | |
US20150347281A1 (en) | Automation testing using descriptive maps | |
CN202339542U (en) | Software product test system | |
CN102135938A (en) | Software product testing method and system | |
CN110221968A (en) | Method for testing software and Related product | |
CN112199086A (en) | Automatic programming control system, method, device, electronic device and storage medium | |
CN104915297B (en) | A kind of automated testing method of the APP power consumption of android equipment | |
CN109508298B (en) | Graphical script test method and system | |
WO2020228283A1 (en) | Feature extraction method and apparatus, and computer readable storage medium | |
CN109388376A (en) | Risk of software development appraisal procedure, device, equipment and readable storage medium storing program for executing | |
CN112214210A (en) | Logistics business rule engine and configuration method, device, equipment and storage medium thereof | |
CN109344066A (en) | A kind of test method of browser page, system and terminal | |
CN108920382B (en) | Test case generation method and device, storage medium and server | |
CN106371997A (en) | Code checking method and device | |
CN106502770A (en) | A kind of HMI state transfer methods based on finite state machine | |
CN114385150A (en) | Low code development method based on intelligent engine | |
US20240086165A1 (en) | Systems and methods for building and deploying machine learning applications | |
CN111273980B (en) | Interface thread visualization method and device, computer equipment and storage medium | |
Fahringer et al. | Teuta: Tool support for performance modeling of distributed and parallel applications | |
CN109376162A (en) | Table data processing method, terminal device and computer readable storage medium | |
CN103116495B (en) | Based on automatic storage method and the device of the single-chip microcomputer register value of IDE | |
CN110389886A (en) | A kind of additional function test method, device and the storage medium of main body application program | |
CN114416210B (en) | Method, device, medium and equipment for simulating decision flow |
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 |