CN103559136A - Method and test system for intelligently executing script on mobile terminal - Google Patents
Method and test system for intelligently executing script on mobile terminal Download PDFInfo
- Publication number
- CN103559136A CN103559136A CN201310594272.4A CN201310594272A CN103559136A CN 103559136 A CN103559136 A CN 103559136A CN 201310594272 A CN201310594272 A CN 201310594272A CN 103559136 A CN103559136 A CN 103559136A
- Authority
- CN
- China
- Prior art keywords
- script
- unit
- condition
- judge whether
- time delay
- 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.)
- Granted
Links
Images
Landscapes
- Debugging And Monitoring (AREA)
- Telephone Function (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The invention provides a method and a test system for intelligently executing a script on a mobile terminal. The method comprises the steps as follows: A, preparing a script file; B, analyzing script statements; C, judging whether an operation is delayed or not, and if the operation is delayed, turning to Step B; D, judging whether an abnormity occurs or not, and if the abnormity occurs, eliminating the abnormity; E, judging whether an operational condition is provided or not, if the operational condition is not provided, delaying time and judging whether the time is exceeded or not, if the time is exceeded, ending the operation, and if the time is not exceeded, continuing to judge whether the operational condition is provided or not, so that script execution failure caused by network conditions and computing power is reduced; F, sending an operational command; and G, judging whether the process is ended or not, if the process is ended, ending the operation, and if the process is not ended, turning to Step B.
Description
Technical field
The present invention relates to software test field, relate more specifically to a kind of on mobile terminal intelligence carry out the method and system of test script.
Background technology
Software test is a category of soft project, and the important means as guaranteeing software quality and reliability occupies an important position in whole software life-cycle, accounts for the more than 60% of whole cost of development.Software test is a complicated process, especially manual test need to expend huge human and material resources and time, tester needs to design, carries out, analyzes a large amount of test cases, thereby manual test efficiency is very low, this also makes the expense in software test stage high, accounts for the 40%-50% of whole software development cost.Therefore, the automaticity that improves Software Testing Tool is to guarantee software development quality, reduces one of important means of software development cost.
Software test automation, from this huge discipline development of computing machine so far, the most basic meaning is the complicacy that solves hand labour, becomes the best instrument that substitutes some repeated behavior pattern.Software automated testing, as the Yi Ge branch of software testing technology, is a kind of measuring technology emerging on the basis of traditional code debugging and black box manual test.
Meanwhile, along with the fast development of mobile Internet, the quantity of the model of mobile intelligent terminal and mobile application has all obtained growth at full speed.And the fast development of mobile field makes mobile application affect more and more our life, at mobile terminal, there is every day ten hundreds of software to be developed for mobile subscriber, it is fast that mobile application possesses renewal speed, the feature that life cycle is short, and user is more and more higher to the requirement of function, performance, stability, so also increasing to the demand of automatic test.
And an important factor is exactly test script in automatic test, the executive mode of test script has also determined accuracy and the ease for use of test.In traditional automatic test work, generally in using automated test tool, write after test script, when using data pool (data-driven), first need to utilize the mechanism of instrument itself to create the data structure of the data pool that script is corresponding, then the data that need the data pool that manual modification script is corresponding, test to meet according to data pool data the object that design repeats automatic test script.
For dissimilar script, existing script executive mode is: regularly also carry out in order the operation of stipulating in script.In script, stipulated operating point (as touch screen click, button, control click etc.) and delay time, during execution, in strict accordance with time sequencing, carried out.The shortcoming of this executive mode is that script manner of execution is more inflexible, and in strict accordance with the script flow performing of writing, while there are abnormal conditions, (such as system, having ejected upgrade tip etc.) cannot run succeeded, and is difficult to carry out result differentiation.
Summary of the invention
In view of this, the present invention mainly solves the deficiency of above-mentioned existing script manner of execution, and when carrying out script, each step all adopts intelligent distinguishing, only at each, walks out of while having showed the result of wanting, and just carries out next step and operates, and accuracy is high; And automatically get rid of the abnormal conditions in some implementations, that guarantees that script can be correct is performed.
The fundamental purpose of the embodiment of the present invention be to provide a kind of on mobile terminal intelligence carry out the method for script, by the certain duration of circular wait, because of the script that network condition and computing power cause, carry out unsuccessfully reducing.
Meanwhile, the another fundamental purpose of the embodiment of the present invention be to provide a kind of on mobile terminal intelligence carry out the test macro of script, by the certain duration of circular wait, because of the script that network condition and computing power cause, carry out unsuccessfully reducing.
For achieving the above object, technical scheme of the present invention is achieved in that
On mobile terminal, intelligence is carried out a method for script, it is characterized in that, comprises the following steps:
A, preparation script file;
B, parsing script sentence;
Whether time delay of C, decision operation, if time delay turns to step B;
D, judge whether to occur abnormal, if so, remove abnormal;
E, judge whether to possess exercisable condition, if not, carry out time delay and judge whether overtimely, if so, end operation, if not, continues to judge whether to possess exercisable condition, carries out unsuccessfully reducing because of the script that network condition and computing power cause;
F, transmit operation instruction;
G, judge whether to finish, if so, end operation, if not, turns to step B.
Preferably, in above-mentioned steps D, extremely refer to, in test process, script is carried out to the interference producing.
Preferably, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
Preferably, in above-mentioned steps E, exercisable condition judges whether button exists before comprising button click.
Preferably, in above-mentioned steps E, by control, detect or image comparison method judges whether to possess exercisable condition.
Meanwhile, the present invention also provide a kind of on mobile terminal intelligence carry out the test macro of script, it is characterized in that, comprise with lower unit:
Preparatory unit, for preparing script file;
Resolution unit, for resolving script sentence;
Delay unit, for whether time delay of decision operation, if resolution unit is enabled in time delay;
Anomaly unit, occurs extremely for judging whether, if so, removes abnormal;
Operating unit, possesses exercisable condition for judging whether, if not, carry out time delay and judge whether overtime, if so, end operation, if not, continue to judge whether to possess exercisable condition, because of the script that network condition and computing power cause, carry out unsuccessfully reducing;
Transmitting element, for transmit operation instruction;
End unit, finishes for judging whether, if so, end operation, if not, enables resolution unit.
Preferably, in above-mentioned anomaly unit, extremely refer to, in test process, script is carried out to the interference producing.
Preferably, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
Preferably, in aforesaid operations unit, exercisable condition judges whether button exists before comprising button click.
Preferably, in aforesaid operations unit, by control, detect or image comparison method judges whether to possess exercisable condition.
This novel intelligence on mobile terminal is carried out the method and system of script, before every single stepping is carried out, judged whether that unusual condition occurs, including but not limited to system upgrade prompting, program upgrade prompting, other programs, switch to the meetings such as foreground and script is carried out to the situation that causes interference, if there is, removal continues after disturbing to carry out again automatically; And detect or image ratio equity method by control, judge whether to have possessed exercisable condition (judging such as before button click whether button exists), if there is no, the certain duration of circular wait, because of the script that network condition and computing power cause, carry out unsuccessfully reducing, improved the testing efficiency of application software.
Accompanying drawing explanation
Fig. 1 be according to an embodiment of the invention on mobile terminal intelligence carry out the operational flowchart of the method for script.
Embodiment
Believe that the feature and advantage of such scheme of the present invention can be more obvious by the detailed description to specific embodiments of the invention below in conjunction with accompanying drawing.
In the present invention, Fig. 1 be according to an embodiment of the invention on mobile terminal intelligence carry out the operational flowchart of script method.
From the disclosed process flow diagram of Fig. 1, the present invention propose a kind of on mobile terminal intelligence carry out the method for script, it is characterized in that, comprise the following steps:
A, preparation script file;
B, parsing script sentence;
Whether time delay of C, decision operation, if time delay turns to step B;
D, judge whether to occur abnormal, if so, remove abnormal;
E, judge whether to possess exercisable condition, if not, carry out time delay and judge whether overtimely, if so, end operation, if not, continues to judge whether to possess exercisable condition, carries out unsuccessfully reducing because of the script that network condition and computing power cause;
F, transmit operation instruction;
G, judge whether to finish, if so, end operation, if not, turns to step B.
Preferably, in above-mentioned steps D, extremely refer to, in test process, script is carried out to the interference producing.
Preferably, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
Preferably, in above-mentioned steps E, exercisable condition judges whether button exists before comprising button click.
Preferably, in above-mentioned steps E, by control, detect or image comparison method judges whether to possess exercisable condition.
In addition, for solving the problems of the technologies described above, the present invention also provide a kind of on mobile terminal intelligence carry out the test macro of script, it is characterized in that, comprise with lower unit:
Preparatory unit, for preparing script file;
Resolution unit, for resolving script sentence;
Delay unit, for whether time delay of decision operation, if resolution unit is enabled in time delay;
Anomaly unit, occurs extremely for judging whether, if so, removes abnormal;
Operating unit, possesses exercisable condition for judging whether, if not, carry out time delay and judge whether overtime, if so, end operation, if not, continue to judge whether to possess exercisable condition, because of the script that network condition and computing power cause, carry out unsuccessfully reducing;
Transmitting element, for transmit operation instruction;
End unit, finishes for judging whether, if so, end operation, if not, enables resolution unit.
Preferably, in above-mentioned anomaly unit, extremely refer to, in test process, script is carried out to the interference producing.
Preferably, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
Preferably, in aforesaid operations unit, exercisable condition judges whether button exists before comprising button click.
Preferably, in aforesaid operations unit, by control, detect or image comparison method judges whether to possess exercisable condition.
Remote real machine adjustment method and the system of this novel application software of mobile terminal, effectively getting rid of some affects the correct unusual condition of carrying out of script; Because each walks all testing conditions, whether possess, so can effectively reduce (should not occur) mortality, such as the emergency situations such as network condition is poor or equipment computing power is poor, improved the testing efficiency of mobile application software.
Claims (10)
1. a method for intelligence execution script on mobile terminal, is characterized in that, comprises the following steps:
A, preparation script file;
B, parsing script sentence;
Whether time delay of C, decision operation, if time delay turns to step B;
D, judge whether to occur abnormal, if so, remove abnormal;
E, judge whether to possess exercisable condition, if not, carry out time delay and judge whether overtimely, if so, end operation, if not, continues to judge whether to possess exercisable condition, carries out unsuccessfully reducing because of the script that network condition and computing power cause;
F, transmit operation instruction;
G, judge whether to finish, if so, end operation, if not, turns to step B.
2. method according to claim 1, is characterized in that, in above-mentioned steps D, extremely refers to, in test process, script is carried out to the interference producing.
3. method according to claim 2, is characterized in that, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
4. method according to claim 1, is characterized in that, in above-mentioned steps E, exercisable condition judges whether button exists before comprising button click.
5. method according to claim 1, is characterized in that, in above-mentioned steps E, by control, detects or image comparison method judges whether to possess exercisable condition.
6. a test macro for intelligence execution script on mobile terminal, is characterized in that, comprises with lower unit:
Preparatory unit, for preparing script file;
Resolution unit, for resolving script sentence;
Delay unit, for whether time delay of decision operation, if resolution unit is enabled in time delay;
Anomaly unit, occurs extremely for judging whether, if so, removes abnormal;
Operating unit, possesses exercisable condition for judging whether, if not, carry out time delay and judge whether overtime, if so, end operation, if not, continue to judge whether to possess exercisable condition, because of the script that network condition and computing power cause, carry out unsuccessfully reducing;
Transmitting element, for transmit operation instruction;
End unit, finishes for judging whether, if so, end operation, if not, enables resolution unit.
7. system according to claim 6, is characterized in that, in above-mentioned anomaly unit, extremely refers to, in test process, script is carried out to the interference producing.
8. system according to claim 7, is characterized in that, above-mentioned interference comprises that system upgrade prompting, program upgrade prompting or other programs switch to the operation on foreground.
9. system according to claim 6, is characterized in that, in aforesaid operations unit, exercisable condition judges whether button exists before comprising button click.
10. system according to claim 6, is characterized in that, in aforesaid operations unit, by control, detects or image comparison method judges whether to possess exercisable condition.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201310594272.4A CN103559136B (en) | 2013-11-22 | A kind of intelligence on mobile terminals performs method and the test system of script |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201310594272.4A CN103559136B (en) | 2013-11-22 | A kind of intelligence on mobile terminals performs method and the test system of script |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN103559136A true CN103559136A (en) | 2014-02-05 |
| CN103559136B CN103559136B (en) | 2016-11-30 |
Family
ID=
Cited By (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103914387A (en) * | 2014-04-23 | 2014-07-09 | 广东欧珀移动通信有限公司 | Method and device for eliminating abnormal interference in Android mobile phone automated testing process |
| CN104461760A (en) * | 2014-11-28 | 2015-03-25 | 北京奇虎科技有限公司 | Script issuing method, device and system |
| CN105183643A (en) * | 2015-08-18 | 2015-12-23 | 惠州Tcl移动通信有限公司 | Automatic testing interference preventing method and apparatus for Android mobile terminal |
| CN109150281A (en) * | 2017-06-27 | 2019-01-04 | 航天恒星科技有限公司 | Automatic operation method of satellite ground station |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101482849A (en) * | 2009-02-24 | 2009-07-15 | 北京星网锐捷网络技术有限公司 | Test monitoring method and apparatus |
| CN101645033A (en) * | 2009-05-15 | 2010-02-10 | 上海闻泰电子科技有限公司 | Debugging method in abnormality of mobile phone software |
| CN101721228A (en) * | 2009-10-21 | 2010-06-09 | 无锡祥生科技有限公司 | Script driving based automatic test method of ultrasonic diagnosis equipment |
| US7739115B1 (en) * | 2001-02-15 | 2010-06-15 | West Corporation | Script compliance and agent feedback |
| CN102495798A (en) * | 2011-12-01 | 2012-06-13 | 盛科网络(苏州)有限公司 | Automated regression testing method and system |
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US7739115B1 (en) * | 2001-02-15 | 2010-06-15 | West Corporation | Script compliance and agent feedback |
| CN101482849A (en) * | 2009-02-24 | 2009-07-15 | 北京星网锐捷网络技术有限公司 | Test monitoring method and apparatus |
| CN101645033A (en) * | 2009-05-15 | 2010-02-10 | 上海闻泰电子科技有限公司 | Debugging method in abnormality of mobile phone software |
| CN101721228A (en) * | 2009-10-21 | 2010-06-09 | 无锡祥生科技有限公司 | Script driving based automatic test method of ultrasonic diagnosis equipment |
| CN102495798A (en) * | 2011-12-01 | 2012-06-13 | 盛科网络(苏州)有限公司 | Automated regression testing method and system |
Cited By (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN103914387A (en) * | 2014-04-23 | 2014-07-09 | 广东欧珀移动通信有限公司 | Method and device for eliminating abnormal interference in Android mobile phone automated testing process |
| CN103914387B (en) * | 2014-04-23 | 2016-08-17 | 广东欧珀移动通信有限公司 | The method and apparatus getting rid of abnormal interference in Android phone automatic test course |
| CN104461760A (en) * | 2014-11-28 | 2015-03-25 | 北京奇虎科技有限公司 | Script issuing method, device and system |
| CN105183643A (en) * | 2015-08-18 | 2015-12-23 | 惠州Tcl移动通信有限公司 | Automatic testing interference preventing method and apparatus for Android mobile terminal |
| CN105183643B (en) * | 2015-08-18 | 2020-09-29 | Tcl移动通信科技(宁波)有限公司 | Automatic testing anti-interference device of android mobile terminal |
| CN109150281A (en) * | 2017-06-27 | 2019-01-04 | 航天恒星科技有限公司 | Automatic operation method of satellite ground station |
| CN109150281B (en) * | 2017-06-27 | 2021-12-28 | 航天恒星科技有限公司 | Automatic operation method for satellite ground station |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN103123598B (en) | Online debugging implementation method of compiling soft programmable logic controller (PLC) | |
| CN108897676B (en) | Flight guidance control software reliability analysis system and method based on formalization rules | |
| CN103268289B (en) | Record the method and system of application testing script on mobile terminals | |
| CN102184138B (en) | Method and system for automatically reproducing and positioning software error | |
| CN103164328B (en) | The regression testing method of a kind of business function, Apparatus and system | |
| CN103729288A (en) | Application program debugging method under embedded multi-core environment | |
| CN108319555A (en) | A kind of real-time adjustment method based on embedded real time system | |
| CN102609472A (en) | Method and system for implementing performance test of distributed database system | |
| EP4181476A1 (en) | Network data analysis method, network data analysis functional network element and communication system | |
| CN112860362B (en) | Visual debugging method and system for robot automation process | |
| CN107844331A (en) | Generate the method, apparatus and equipment of boot configuration file | |
| CN102541735A (en) | Automatic software test method | |
| CN107608772B (en) | Method and system for batch processing task configuration scheduling | |
| CN118467032A (en) | Automated UI interaction exploration method based on multimodal large model | |
| CN103092747A (en) | Controlling program verifying and testing method and system thereof | |
| CN109656801B (en) | Business flow test case automatic generation system based on path adaptive technology | |
| CN112306836B (en) | Sampling object determining method, apparatus, electronic device storage medium and program product | |
| CN106686179A (en) | Mobile phone power consumption testing system and method based on test automation | |
| CN103559136A (en) | Method and test system for intelligently executing script on mobile terminal | |
| US20190213108A1 (en) | Method that supports multithreading/concurrent programming debugging, computer readable recording medium and computer program product | |
| CN103559136B (en) | A kind of intelligence on mobile terminals performs method and the test system of script | |
| CN109739127B (en) | Intelligent program-controlled information capturing method | |
| CN111124893B (en) | Automatic testing method and system based on Android device | |
| CN201123074Y (en) | Testing device for detecting stability of set-top box | |
| CN116341163B (en) | A thermal hydraulic calculation method based on nuclear power simulation platform |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| C06 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| C14 | Grant of patent or utility model | ||
| GR01 | Patent grant |