CN106547687A - Application testing method, apparatus and system - Google Patents

Application testing method, apparatus and system Download PDF

Info

Publication number
CN106547687A
CN106547687A CN201610900642.6A CN201610900642A CN106547687A CN 106547687 A CN106547687 A CN 106547687A CN 201610900642 A CN201610900642 A CN 201610900642A CN 106547687 A CN106547687 A CN 106547687A
Authority
CN
China
Prior art keywords
test
application
measured terminal
service end
terminal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201610900642.6A
Other languages
Chinese (zh)
Inventor
卢道和
方镇举
韩海燕
陈朝亮
杨军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
WeBank Co Ltd
Original Assignee
WeBank 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 WeBank Co Ltd filed Critical WeBank Co Ltd
Priority to CN201610900642.6A priority Critical patent/CN106547687A/en
Publication of CN106547687A publication Critical patent/CN106547687A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites

Abstract

The invention discloses a kind of application testing method, is applied to service end, the service end is communicated to connect with measured terminal by data wire, and the application testing method includes:Service end calls Android to debug bridge to measured terminal execution system initialization operation;After the completion of system initialization, if receiving using test instruction, test suite is called;According to the test suite for calling, in the test script for prestoring, corresponding test script program segment is extracted based on application test instruction;The test script program segment for extracting is sent to the measured terminal, is tested with the application to the measured terminal.The invention also discloses a kind of apply test device and system.The present invention improves the efficiency and convenience using test.

Description

Application testing method, apparatus and system
Technical field
The present invention relates to field of computer technology, more particularly to a kind of application testing method, apparatus and system.
Background technology
At present, some applications in terminal are tested, typically all first generates test script, then test script is sent out It is sent in terminal, is tested in the terminal, if being tested to application using this test mode, every time to different application Tested, be required for (resetting) mobile phone again Root, if the multiple applications in terminal are tested, it is necessary to constantly Root termination, cause the testing efficiency applied low, and repeatedly root termination, the test process to applying is comparatively laborious.
The content of the invention
Present invention is primarily targeted at proposing a kind of application testing method, apparatus and system, it is intended to solve existing answering With test mode, the relatively low technical problem of testing efficiency and convenience.
For achieving the above object, a kind of application testing method that the present invention is provided, is applied to service end, and the service end is led to Cross data wire to communicate to connect with measured terminal, the application testing method includes:
Service end calls Android to debug bridge to measured terminal execution system initialization operation;
After the completion of system initialization, if receiving using test instruction, test suite is called;
According to the test suite for calling, in the test script for prestoring, phase is extracted based on application test instruction The test script program segment answered;
The test script program segment for extracting is sent to the measured terminal, is entered with the application to the measured terminal Row test.
Preferably, if described receive using test instruction, include the step of call test suite:
The service end tests the application programming interfaces API versions that instruction determines the measured terminal according to the application;
Call the corresponding test suite of the API versions.
Preferably, the step of test script program segment by extraction is sent to the measured terminal includes:
The service end monitors the measured terminal;
When the terminal prot of the measured terminal feedback is received, the test script program segment for extracting is sent To the measured terminal, wherein, the terminal prot number is initial in the system for detecting the service end by the measured terminal Feed back when change is completed.
Preferably, it is described the test script program segment for extracting to be sent to after the step of the measured terminal, institute Stating application testing method also includes:
After the completion of the test script is performed, the service end carries out sectional drawing to the test process of the measured terminal;
The test result file of preset format is generated according to the picture for intercepting.
Additionally, for achieving the above object, the present invention also proposes one kind application test device, is applied to service end, the clothes Business end is communicated to connect with measured terminal by data wire, and the application test device includes:
Calling module, for calling Android to debug bridge to measured terminal execution system initialization operation;
The calling module, is additionally operable to after the completion of system initialization, if receiving using test instruction, calls test group Part;
Extraction module, for according to the test suite for calling, in the test script for prestoring, is surveyed based on the application Corresponding test script program segment is extracted in examination instruction;
Sending module, for the test script program segment for extracting is sent to the measured terminal, with to the quilt The application for surveying terminal is tested.
Preferably, the calling module includes:
Determining unit, for testing the application programming interfaces API versions that instruction determines the measured terminal according to the application This;
Call unit, for calling the corresponding test suite of the API versions.
Preferably, the sending module includes:
Monitoring unit, for monitoring the measured terminal;
Transmitting element, for when the terminal prot of measured terminal feedback is received, the test that will be extracted Shell script section is sent to the measured terminal, wherein, the terminal prot number is detecting the clothes by the measured terminal The system initialization at business end is fed back when completing.
Preferably, the application test device also includes:
Screen capture module, after the completion of performing in the test script, carries out cutting to the test process of the measured terminal Figure;
Generation module, for the test result file of preset format is generated according to the picture for intercepting.
Additionally, for achieving the above object, the present invention also proposes a kind of application test systems, and the application test systems include Service end and the measured terminal communicated to connect with the service end by data wire, service end application as described above are surveyed Trial assembly is put, and the measured terminal includes:
Starting module, during for completing in the system initialization for detecting service end, starts the kit of deployment;
Receiver module, for based on the kit for starting, receiving the test script program segment that the service end sends;
Processing module, for calling test suite to the test script program performing application test process that receives.
Preferably, the receiver module includes:
Transmitting element, for based on the kit for starting, the terminal prot number for sending the measured terminal is extremely described Service end, so that the service end feeds back the test script program segment based on the terminal prot number, wherein, it is described to send single Unit is additionally operable to for every instruction execution result to feed back to the service end;
Receiving unit, for receiving the test script program segment of the service end feedback.
Application testing method proposed by the present invention, apparatus and system, service end first call Android to debug bridge to measured terminal Execution system initialization operation, after the completion of system initialization, if receiving using test instruction, calls test suite, then According to the test suite for calling, in the test script for prestoring, corresponding test is extracted based on application test instruction Shell script section, the test script program segment for most extracting at last are sent to the measured terminal, with to the measured terminal Application tested, realize when testing to applications different in measured terminal, different surveys need not be installed in terminal Training sheet, as long as sending different test script programs to measured terminal by service end, without multiple Root measured terminals, The efficiency using test is not only increased, the convenience using test is also improved.
Description of the drawings
Fig. 1 is the schematic flow sheet of application testing method first embodiment of the present invention;
If Fig. 2 is received using test instruction for the present invention, the refinement schematic flow sheet of test suite is called;
Fig. 3 is that the test script program segment for extracting is sent to the refinement flow process signal of the measured terminal by the present invention Figure;
Fig. 4 is the schematic flow sheet of application testing method second embodiment of the present invention;
Fig. 5 is high-level schematic functional block diagram of the present invention using test device first embodiment;
Fig. 6 is the refinement high-level schematic functional block diagram of calling module in Fig. 5;
Fig. 7 is the refinement high-level schematic functional block diagram of sending module in Fig. 5;
Fig. 8 is high-level schematic functional block diagram of the present invention using test device second embodiment;
Fig. 9 is the high-level schematic functional block diagram of application test systems preferred embodiment of the present invention;
Figure 10 is the refinement high-level schematic functional block diagram of receiver module in Fig. 9.
The realization of the object of the invention, functional characteristics and advantage will be described further in conjunction with the embodiments referring to the drawings.
Specific embodiment
It should be appreciated that specific embodiment described herein is not intended to limit the present invention only to explain the present invention.
The solution of the embodiment of the present invention is mainly:Service end first calls Android to debug bridge to measured terminal execution system Initialization operation, after the completion of system initialization, if receiving using test instruction, calls test suite, and then basis is called The test suite, in the test script for prestoring, corresponding test script program is extracted based on application test instruction Section, the test script program segment for most extracting at last are sent to the measured terminal, are entered with the application to the measured terminal Row test, realizes when testing to applications different in measured terminal, need not install different test scripts in terminal, only Different test script programs are sent to measured terminal by service end, without multiple Root measured terminals, not only be improved The efficiency of application test, also improves the convenience using test.
The present invention is passed to the test script for prestoring by number by the automated test tool in service end (i.e. PC) It is connected on the measured terminal (i.e. mobile phone) of PC according to line, it is not necessary to which test script instruction just can be delivered to mobile phone by mobile phone root On, so as to realize the test to applying on mobile phone.
The present invention provides a kind of application testing method, is applied to service end.
With reference to Fig. 1, Fig. 1 is the schematic flow sheet of application testing method first embodiment of the present invention.
In the present embodiment, the service end is communicated to connect with measured terminal by data wire, the application testing method Including:
Step S10, service end call Android to debug bridge to measured terminal execution system initialization operation;
In the present embodiment, before execution step S10, need first to set up test script, the foundation of the test script Step is as follows:
Obtain element:The page elements for needing operation are taken out with Android device watch-dog, the side of current location element Method is had;
According to actual test scene, the exploitation of test script is carried out according to the above-mentioned element for getting, in test script Need addition to assert, corresponding test result can be just seen when such test execution terminates, asserts it can is element Text, can be interface picture contrast etc..
It should be noted that during the foundation of test script, each step will click on the order of UI in strict accordance with user Write, it is impossible to hopping sequence, otherwise occur that the exception that can not find element reports an error.
After the completion of test script is set up, the test script of foundation is stored, then service end calls Android to debug Bridge is operated with completing basic system initialization.
Step S20, after the completion of system initialization, if receiving using test instruction, calls test suite;
After the completion of system initialization, start the automated test tool in service end, and when daily record output display is tested After terminal has been connected, just follow-up test process can be performed according to the test script of service end.If now receiving application Test instruction, then call test suite.In the present embodiment, with reference to Fig. 2, step S20 includes:
Step S21, the service end test the application programming interfaces that instruction determines the measured terminal according to the application API versions;
Step S22, calls the corresponding test suite of the API versions.
That is, when automated test tool test script is run in service end, the automation in service end is surveyed Trial work tool can be by corresponding test command with JSON's (JavaScript Object Notation, a kind of data transmission format) Form is sent to server, and server then can call different test groups according to the version of measured terminal Android api interface Part, in the present embodiment, preferred API versions call selendroid less than 17, call UIautomator more than or equal to 17.
Step S30, according to the test suite for calling, in the test script for prestoring, is referred to based on application test Corresponding test script program segment is extracted in order;
After the corresponding test suite of the API versions is called, according to the test suite for calling, you can prestoring Test script in, corresponding test script program segment is extracted based on application test instruction, that is to say, that in the survey for prestoring In training sheet, the corresponding test script program segment of the application test instruction is extracted.
Step S40, the test script program segment for extracting is sent to the measured terminal, with to the measured terminal Application tested.
After the corresponding test script program segment of application test instruction is extracted, can directly will be described in extraction Test script program segment is sent to the measured terminal connected by data wire, is surveyed with the application to the measured terminal Examination.Specifically, with reference to Fig. 3, step S40 includes:
Step S41, the service end monitor the measured terminal;
Step S42, when the terminal prot of the measured terminal feedback is received, the test script journey that will be extracted Sequence section is sent to the measured terminal, wherein, the terminal prot number is detecting the service end by the measured terminal Feed back when system initialization is completed.
I.e. described service end first monitors the measured terminal in real time, to receive the terminal prot of the measured terminal feedback Number, wherein, the terminal prot number is fed back when the system initialization for detecting the service end is completed by the measured terminal. Specifically, the measured terminal first starts the kit of deployment, Ran Houji when the system initialization for detecting service end is completed In the kit for starting, the terminal prot number of the measured terminal is sent to the service end, for the service end group The test script program segment is fed back in the terminal prot number.It should be noted that the Main Function of this kit is to disappear The transmission of breath and test suite scheduling.
The service end parses the application test life when the terminal prot of the measured terminal feedback is received Order, then extracts corresponding test script program segment according to the application test command for having parsed in test script, then by institute State the kit that the test script program segment of extraction is issued measured terminal for terminal prot number corresponding port.By the tested end The kit at end calls test suite to complete actual concrete test operation in measured terminal.
The application testing method that the present embodiment is proposed, service end first call Android to debug bridge at the beginning of measured terminal execution system Beginningization is operated, and after the completion of system initialization, if receiving using test instruction, calls test suite, and then basis is called The test suite, in the test script for prestoring, extracts corresponding test script program segment based on application test instruction, The test script program segment for most extracting at last is sent to the measured terminal, is surveyed with the application to the measured terminal Examination, realizes when testing to applications different in measured terminal, need not install different test scripts in terminal, as long as by Service end sends different test script programs to measured terminal, and without multiple Root measured terminals, not only increasing should With the efficiency of test, the convenience using test is also improved.
Further, in order to improve the flexibility using test, propose that the present invention applies test side based on first embodiment The second embodiment of method, in the present embodiment, with reference to Fig. 4, after step S40, the application testing method also includes:
Step S50, after the completion of the test script is performed, the service end is entered to the test process of the measured terminal Row sectional drawing;
Step S60, generates the test result file of preset format according to the picture for intercepting.
In the present embodiment, after the completion of test script execution, test process of the service end to measured terminal Sectional drawing is carried out, the test result file of preset format is then generated under catalogue according to the picture for intercepting, the preset format is excellent Elect HTML (Hyper Text Markup Language, HTML) form as.
Further, after testing to measured terminal, if there is test cases to perform failure, send out after having tested Send test result file to default user terminal, mail warning information is such as sent in the way of mail to default mailbox.
Further, in the present invention, in order to improve the flexibility using test, the operation of test application is preferably set in advance Frequency, such as controls how long test script performs once, and the operating frequency is configured as the case may be, so substantially The ruuning situation regular check of some application systems to production environment can be accomplished.
Certainly, in the present invention, if multiple applications needs are tested, then multiple test class can be created each application is entered Row test.
In the present embodiment, after the completion of test script execution, test of the service end to the measured terminal Process carries out sectional drawing, and according to the test result file of the picture generation preset format for intercepting, realizes to service end to tested Terminal carries out after test terminates, generating test result file, being easy to tester to check the destination file tested, improve Using the flexibility of test.
The application testing scheme of the present invention, mainly to the application in mobile phone, the automation that preferred Mobile banking's application is done Test, is mainly distributed on following aspects:
The test of User logs in, the test of human face scanning scene, the test of SMS scene, the survey of querying individual assets Examination, finance product displaying, the test of income, many cooperation row APP are embedded in bank H5 (Hyper Text Markup Language5, the 5th generation HTML) test of page financing, in the test of robot customer service etc. scene, it is above-mentioned Several test scenes, can be judged according to the element in the page to be occurred, page when operation, for performing mistake The scene for losing, can trigger mail alarm.
The testing scheme of the present invention, can voluntarily complete to log in, trigger otp (One-time Password, also referred to as dynamic Password) verification of correctness such as note, face verification, robot customer service, to producing environmental system, normally operation accomplishes fixed to the technology When the monitoring of phase, particularly system update are issued, automatic test script can accomplish the monitoring to service stability, make Completed the automatic test of crawl is replied to producing environment machine device people customer service with the technology, so as to improve the effect using test Rate.
The present invention further provides one kind application test device, is applied to service end.
With reference to Fig. 5, Fig. 5 is high-level schematic functional block diagram of the present invention using test device first embodiment.
It is emphasized that it will be apparent to those skilled in the art that functional block diagram shown in Fig. 5 is only one preferably real The exemplary plot of example is applied, functional module of the those skilled in the art around the application test device shown in Fig. 5 can be carried out new easily Functional module supplement;The title of each functional module is self-defined title, is only used for aiding in understanding this using test device Each program function block, is not used in restriction technical scheme, and the core of technical solution of the present invention is, each self-defined title Functional module function to be reached.
In the present embodiment, the service end is communicated to connect with measured terminal by data wire, the application test device Including:
Calling module 10, for calling Android to debug bridge to measured terminal execution system initialization operation;
In the present embodiment, also including module is set up, for calling Android to debug bridge to measured terminal in calling module 10 Before execution system initialization operation, test script is first set up, the foundation for module being set up to test script is as follows:
Obtain element:The page elements for needing operation are taken out with Android device watch-dog, the side of current location element Method is had;
According to actual test scene, the exploitation of test script is carried out according to the above-mentioned element for getting, in test script Need addition to assert, corresponding test result can be just seen when such test execution terminates, asserts it can is element Text, can be interface picture contrast etc..
It should be noted that during the foundation of test script, each step will click on the order of UI in strict accordance with user Write, it is impossible to hopping sequence, otherwise occur that the exception that can not find element reports an error.
After the completion of module is set up to test script foundation, the test script of foundation is stored, then calling module 10 call Android debugging bridge to complete basic system initialization operation.
The calling module 10, is additionally operable to after the completion of system initialization, if receiving using test instruction, calls test Component;
After the completion of system initialization, start the automated test tool in service end, and when daily record output display is tested After terminal has been connected, just follow-up test process can be performed according to the test script of service end.If now receiving application Test instruction, then the calling module 10 calls test suite.In the present embodiment, specifically, with reference to Fig. 6, the calling module 10 include:
Determining unit 11, for testing the application programming interfaces API that instruction determines the measured terminal according to the application Version;
Call unit 12, for calling the corresponding test suite of the API versions.
That is, when automated test tool test script is run in service end, the calling module 10 can lead to With JSON, (JavaScript Object Notation, a kind of data are passed by corresponding test command to cross automated test tool Transport format) form be sent to server, and server then can call difference according to the version of measured terminal Android api interface Test suite, in the present embodiment, preferred API versions call selendroid less than 17, call more than or equal to 17 UIautomator。
Extraction module 20, for according to the test suite for calling, in the test script for prestoring, based on the application Corresponding test script program segment is extracted in test instruction;
After calling module 10 calls the corresponding test suite of the API versions, extraction module 20 is according to the institute called State test suite, you can in the test script for prestoring, corresponding test script program is extracted based on application test instruction Section, that is to say, that extraction module 20 extracts the corresponding test script journey of the application test instruction in the test script for prestoring Sequence section.
Sending module 30, for the test script program segment for extracting is sent to the measured terminal, with to described The application of measured terminal is tested.
After extraction module 20 extracts the corresponding test script program segment of the application test instruction, sending module 30 Directly the test script program segment for extracting can be sent to the measured terminal connected by data wire, with to described The application of measured terminal is tested.Specifically, with reference to Fig. 7, the sending module 30 includes:
Monitoring unit 31, for monitoring the measured terminal;
Transmitting element 32, for when the terminal prot of measured terminal feedback is received, the survey that will be extracted Training this program segment is sent to the measured terminal, wherein, the terminal prot number by the measured terminal detect it is described Feed back when the system initialization of service end is completed.
I.e. monitoring unit 31 first monitors the measured terminal in real time, to receive the terminal prot of the measured terminal feedback Number, wherein, the terminal prot number is fed back when the system initialization for detecting the service end is completed by the measured terminal. Specifically, the measured terminal first starts the kit of deployment, Ran Houji when the system initialization for detecting service end is completed In the kit for starting, the terminal prot number of the measured terminal is sent to the service end, for the service end group The test script program segment is fed back in the terminal prot number.It should be noted that the Main Function of this kit is to disappear The transmission of breath and test suite scheduling.
When the terminal prot of the measured terminal feedback is received, the application test command is parsed, then basis The application test command for having parsed extracts corresponding test script program segment in test script, and transmitting element 32 is again by described Terminal prot number corresponding port is issued the kit of measured terminal by the test script program segment of extraction.By the measured terminal Kit in measured terminal, call test suite to complete actual concrete test operation.
The application test device that the present embodiment is proposed, service end first call Android to debug bridge at the beginning of measured terminal execution system Beginningization is operated, and after the completion of system initialization, if receiving using test instruction, calls test suite, and then basis is called The test suite, in the test script for prestoring, extracts corresponding test script program segment based on application test instruction, The test script program segment for most extracting at last is sent to the measured terminal, is surveyed with the application to the measured terminal Examination, realizes when testing to applications different in measured terminal, need not install different test scripts in terminal, as long as by Service end sends different test script programs to measured terminal, and without multiple Root measured terminals, not only increasing should With the efficiency of test, the convenience using test is also improved.
Further, in order to improve the flexibility using test, present invention application test dress is proposed based on first embodiment The second embodiment put, in the present embodiment, with reference to Fig. 8, the application test device also includes:
Screen capture module 40, after the completion of performing in the test script, is carried out to the test process of the measured terminal Sectional drawing;
Generation module 50, for the test result file of preset format is generated according to the picture for intercepting.
In the present embodiment, after the completion of test script execution, test process of the screen capture module 40 to measured terminal Sectional drawing is carried out, then generation module 50 generates the test result file of preset format under catalogue according to the picture for intercepting, described Preset format is preferably HTML (Hyper Text Markup Language, HTML) form.
Further, after testing to measured terminal, if there is test cases to perform failure, the sending module 30 send test result file after having tested to default user terminal, and mail warning information is such as sent in the way of mail extremely Default mailbox.
Further, in the present invention, in order to improve the flexibility using test, the operation of test application is preferably set in advance Frequency, such as controls how long test script performs once, and the operating frequency is configured as the case may be, so substantially The ruuning situation regular check of some application systems to production environment can be accomplished.
Certainly, in the present invention, if multiple applications needs are tested, then multiple test class can be created each application is entered Row test.
In the present embodiment, after the completion of test script execution, test of the service end to the measured terminal Process carries out sectional drawing, and according to the test result file of the picture generation preset format for intercepting, realizes to service end to tested Terminal carries out after test terminates, generating test result file, being easy to tester to check the destination file tested, improve Using the flexibility of test.
The application testing scheme of the present invention, mainly to the application in mobile phone, the automation that preferred Mobile banking's application is done Test, is mainly distributed on following aspects:
The test of User logs in, the test of human face scanning scene, the test of SMS scene, the survey of querying individual assets Examination, finance product displaying, the test of income, many cooperation row APP are embedded in bank H5 (Hyper Text Markup Language5, the 5th generation HTML) test of page financing, in the test of robot customer service etc. scene, it is above-mentioned Several test scenes, can be judged according to the element in the page to be occurred, page when operation, for performing mistake The scene for losing, can trigger mail alarm.
The testing scheme of the present invention, can voluntarily complete to log in, trigger otp (One-time Password, also referred to as dynamic Password) verification of correctness such as note, face verification, robot customer service, to producing environmental system, normally operation accomplishes fixed to the technology When the monitoring of phase, particularly system update are issued, automatic test script can accomplish the monitoring to service stability, make Completed the automatic test of crawl is replied to producing environment machine device people customer service with the technology, so as to improve the effect using test Rate.
The present invention further provides a kind of application test systems.
With reference to Fig. 9, Fig. 9 is the high-level schematic functional block diagram of application test systems preferred embodiment of the present invention.
In the present embodiment, the application test systems include service end and by data wire and the service end communication link The measured terminal for connecing, service end application test device as described above, the measured terminal include:
Starting module 60, during for completing in the system initialization for detecting service end, starts the kit of deployment;
Receiver module 70, for based on the kit for starting, receiving the test script program that the service end sends Section;
In the present embodiment, starting module 60 starts the work of deployment when the system initialization for detecting service end is completed Tool bag.It should be noted that before the kit of deployment is started, the measured terminal needs first to dispose the kit. After opening the kit of deployment, receiver module 70 receives the test that the service end sends based on the kit for starting Shell script section, specifically, with reference to Figure 10, the receiver module 70 includes:
Transmitting element 71, for based on the kit for starting, sending the terminal prot number of the measured terminal to institute Service end is stated, so that the service end feeds back the test script program segment based on the terminal prot number, wherein, the transmission Unit 71 is additionally operable to for every instruction execution result to feed back to the service end;
Receiving unit 72, for receiving the test script program segment of the service end feedback.
Transmitting element 71 i.e. in the receiver module 70 sends the measured terminal first based on the kit for starting Terminal prot number to the service end, facilitate the transmission of test command, subsequently, the clothes received by the receiving unit 72 The test script program segment of business end feedback.
Processing module 80, for calling the test script program performing application of the test suite to receiving to test Journey.
When receiving unit 72 receives the test script program segment of the service end feedback, processing module 80 is called Test suite to the test script program performing application test process that receives, in the present embodiment, also according to tested end The version of end android API in the present embodiment, is preferably adjusted when API versions are less than 17 calling different test suites With selendroid, UIautomator is called when API versions are more than or equal to 17.
In the present embodiment, when the system initialization for detecting service end is completed, starting module starts the instrument of deployment Bag, receiver module based on the kit for starting, receive the test script program segment that the service end sends, final process again Module calls test suite to the test script program performing application test process for receiving, and realizes in measured terminal When different applications is tested, different test scripts need not be installed in terminal, as long as different tests are sent by service end Shell script without multiple Root measured terminals, not only increases the efficiency using test, also improves to measured terminal Using the convenience of test.
It should be noted that herein, term " including ", "comprising" or its any other variant are intended to non-row His property is included, so that a series of process, method, article or device including key elements not only include those key elements, and And also include other key elements being not expressly set out, or also include for this process, method, article or device institute inherently Key element.In the absence of more restrictions, the key element for being limited by sentence "including a ...", it is not excluded that including being somebody's turn to do Also there is other identical element in the process of key element, method, article or device.
The embodiments of the present invention are for illustration only, do not represent the quality of embodiment.
Through the above description of the embodiments, those skilled in the art can be understood that above-described embodiment side Method can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but in many cases The former is more preferably embodiment.Based on such understanding, technical scheme is substantially done to prior art in other words The part for going out contribution can be embodied in the form of software product, and the computer software product is stored in a storage medium In (such as ROM/RAM, magnetic disc, CD), use so that a station terminal equipment including some instructions (can be mobile phone, computer, clothes Business device, air-conditioner, or network equipment etc.) perform method described in each embodiment of the invention.
The preferred embodiments of the present invention are these are only, the scope of the claims of the present invention is not thereby limited, it is every using this Equivalent structure or equivalent flow conversion that bright specification and accompanying drawing content are made, or directly or indirectly it is used in other related skills Art field, is included within the scope of the present invention.

Claims (10)

1. a kind of application testing method, it is characterised in that be applied to service end, the service end passes through data wire and measured terminal Communication connection, the application testing method include:
Service end calls Android to debug bridge to measured terminal execution system initialization operation;
After the completion of system initialization, if receiving using test instruction, test suite is called;
According to the test suite for calling, in the test script for prestoring, extract corresponding based on application test instruction Test script program segment;
The test script program segment for extracting is sent to the measured terminal, is surveyed with the application to the measured terminal Examination.
2. application testing method as claimed in claim 1, it is characterised in that if described receive using test instruction, call The step of test suite, includes:
The service end tests the application programming interfaces API versions that instruction determines the measured terminal according to the application;
Call the corresponding test suite of the API versions.
3. application testing method as claimed in claim 1, it is characterised in that the test script program segment that will be extracted The step of sending to the measured terminal includes:
The service end monitors the measured terminal;
When the terminal prot of the measured terminal feedback is received, the test script program segment for extracting is sent to institute Measured terminal is stated, wherein, the terminal prot number is complete in the system initialization for detecting the service end by the measured terminal Into when feed back.
4. the application testing method as described in any one of claim 1-3, it is characterised in that the test pin that will be extracted This program segment is sent to after the step of the measured terminal, and the application testing method also includes:
After the completion of the test script is performed, the service end carries out sectional drawing to the test process of the measured terminal;
The test result file of preset format is generated according to the picture for intercepting.
5. one kind application test device, it is characterised in that be applied to service end, the service end passes through data wire and measured terminal Communication connection, the application test device include:
Calling module, for calling Android to debug bridge to measured terminal execution system initialization operation;
The calling module, is additionally operable to after the completion of system initialization, if receiving using test instruction, calls test suite;
Extraction module, for according to the test suite for calling, in the test script for prestoring, is referred to based on application test Corresponding test script program segment is extracted in order;
Sending module, for the test script program segment for extracting is sent to the measured terminal, with to the tested end The application at end is tested.
6. test device is applied as claimed in claim 5, it is characterised in that the calling module includes:
Determining unit, for testing the application programming interfaces API versions that instruction determines the measured terminal according to the application;
Call unit, for calling the corresponding test suite of the API versions.
7. test device is applied as claimed in claim 6, it is characterised in that the sending module includes:
Monitoring unit, for monitoring the measured terminal;
Transmitting element, for when the terminal prot of measured terminal feedback is received, the test script that will be extracted Program segment is sent to the measured terminal, wherein, the terminal prot number is detecting the service end by the measured terminal System initialization feed back when completing.
8. the application test device as described in any one of claim 5-7, it is characterised in that the application test device is also wrapped Include:
Screen capture module, after the completion of performing in the test script, carries out sectional drawing to the test process of the measured terminal;
Generation module, for the test result file of preset format is generated according to the picture for intercepting.
9. a kind of application test systems, it is characterised in that the application test systems include service end and by data wire and institute State the measured terminal of service end communication connection, application test device of the service end as described in any one of claim 5-8, institute Stating measured terminal includes:
Starting module, during for completing in the system initialization for detecting service end, starts the kit of deployment;
Receiver module, for based on the kit for starting, receiving the test script program segment that the service end sends;
Processing module, for calling test suite to the test script program performing application test process that receives.
10. application test systems as claimed in claim 9, it is characterised in that the receiver module includes:
Transmitting element, for based on the kit for starting, sending the terminal prot number of the measured terminal to the service End, so that the service end feeds back the test script program segment based on the terminal prot number, wherein, the transmitting element is also For every instruction execution result is fed back to the service end;
Receiving unit, for receiving the test script program segment of the service end feedback.
CN201610900642.6A 2016-10-14 2016-10-14 Application testing method, apparatus and system Pending CN106547687A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610900642.6A CN106547687A (en) 2016-10-14 2016-10-14 Application testing method, apparatus and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610900642.6A CN106547687A (en) 2016-10-14 2016-10-14 Application testing method, apparatus and system

Publications (1)

Publication Number Publication Date
CN106547687A true CN106547687A (en) 2017-03-29

Family

ID=58368881

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610900642.6A Pending CN106547687A (en) 2016-10-14 2016-10-14 Application testing method, apparatus and system

Country Status (1)

Country Link
CN (1) CN106547687A (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107122301A (en) * 2017-04-27 2017-09-01 武汉斗鱼网络科技有限公司 Interface detection method and device
CN107391362A (en) * 2017-06-28 2017-11-24 北京珠穆朗玛移动通信有限公司 Application testing method, mobile terminal and storage medium
CN107608896A (en) * 2017-09-26 2018-01-19 上海爱优威软件开发有限公司 The detection method and system of a kind of terminal applies
CN108073483A (en) * 2017-07-31 2018-05-25 北京微应软件科技有限公司 The control method and system of mobile terminal
CN108170607A (en) * 2018-01-03 2018-06-15 上海传英信息技术有限公司 The control device and control method of OTP switches
CN108243284A (en) * 2016-12-26 2018-07-03 中国移动通信有限公司研究院 A kind of dial testing method and device
CN109726100A (en) * 2018-04-19 2019-05-07 平安普惠企业管理有限公司 Application performance test method, apparatus, equipment and computer readable storage medium
CN109828921A (en) * 2019-01-18 2019-05-31 上海极链网络科技有限公司 HTML5 webpage automated function test method, system and electronic equipment
CN110737549A (en) * 2018-07-20 2020-01-31 北京奇虎科技有限公司 Application testing method, device, server and system
CN110990266A (en) * 2019-11-15 2020-04-10 苏州浪潮智能科技有限公司 Method, equipment and storage medium for testing server performance
CN111901471A (en) * 2020-07-06 2020-11-06 珠海世纪鼎利科技股份有限公司 Drive test system and method for non-root android mobile phone
CN113094290A (en) * 2021-05-21 2021-07-09 珠海金山网络游戏科技有限公司 Program test system and method
CN115276844A (en) * 2022-08-02 2022-11-01 上海移柯通信技术股份有限公司 Communication module testing method and device and electronic equipment

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150363304A1 (en) * 2014-06-17 2015-12-17 Kishan Nagamalla Self-learning and self-validating declarative testing
CN105868111A (en) * 2016-03-29 2016-08-17 网易(杭州)网络有限公司 Automatic testing method and device for mobile terminal game
CN105912473A (en) * 2016-04-15 2016-08-31 上海海万信息科技有限公司 BDD-based mobile APP automatic testing platform and testing method

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150363304A1 (en) * 2014-06-17 2015-12-17 Kishan Nagamalla Self-learning and self-validating declarative testing
CN105868111A (en) * 2016-03-29 2016-08-17 网易(杭州)网络有限公司 Automatic testing method and device for mobile terminal game
CN105912473A (en) * 2016-04-15 2016-08-31 上海海万信息科技有限公司 BDD-based mobile APP automatic testing platform and testing method

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
MANOJ HANS: "Chapter 1.Appium–Important Conceptual Background", 《APPIUM.ESSENTIALS》 *
QA SEVEN: "appium手机自动化测试", 《HTTPS://WENKU.BAIDU.COM/VIEW/95DAF550783E0912A3162A22.HTML?FROM=SEARCH》 *
测试之美: "Appium精要之Appium的背景知识", 《HTTPS://WWW.JIANSHU.COM/P/5D11299F674B》 *

Cited By (18)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108243284B (en) * 2016-12-26 2021-09-14 中国移动通信有限公司研究院 Dial testing method and device
CN108243284A (en) * 2016-12-26 2018-07-03 中国移动通信有限公司研究院 A kind of dial testing method and device
CN107122301B (en) * 2017-04-27 2020-04-10 武汉斗鱼网络科技有限公司 Interface testing method and device
CN107122301A (en) * 2017-04-27 2017-09-01 武汉斗鱼网络科技有限公司 Interface detection method and device
CN107391362A (en) * 2017-06-28 2017-11-24 北京珠穆朗玛移动通信有限公司 Application testing method, mobile terminal and storage medium
CN108073483A (en) * 2017-07-31 2018-05-25 北京微应软件科技有限公司 The control method and system of mobile terminal
CN107608896A (en) * 2017-09-26 2018-01-19 上海爱优威软件开发有限公司 The detection method and system of a kind of terminal applies
CN108170607B (en) * 2018-01-03 2021-05-18 上海传英信息技术有限公司 Control device and control method of OTP switch
CN108170607A (en) * 2018-01-03 2018-06-15 上海传英信息技术有限公司 The control device and control method of OTP switches
CN109726100A (en) * 2018-04-19 2019-05-07 平安普惠企业管理有限公司 Application performance test method, apparatus, equipment and computer readable storage medium
CN110737549A (en) * 2018-07-20 2020-01-31 北京奇虎科技有限公司 Application testing method, device, server and system
CN109828921A (en) * 2019-01-18 2019-05-31 上海极链网络科技有限公司 HTML5 webpage automated function test method, system and electronic equipment
CN110990266A (en) * 2019-11-15 2020-04-10 苏州浪潮智能科技有限公司 Method, equipment and storage medium for testing server performance
CN110990266B (en) * 2019-11-15 2022-12-16 苏州浪潮智能科技有限公司 Method, equipment and storage medium for testing server performance
CN111901471A (en) * 2020-07-06 2020-11-06 珠海世纪鼎利科技股份有限公司 Drive test system and method for non-root android mobile phone
CN113094290A (en) * 2021-05-21 2021-07-09 珠海金山网络游戏科技有限公司 Program test system and method
CN113094290B (en) * 2021-05-21 2024-02-23 珠海金山数字网络科技有限公司 Program testing system and method
CN115276844A (en) * 2022-08-02 2022-11-01 上海移柯通信技术股份有限公司 Communication module testing method and device and electronic equipment

Similar Documents

Publication Publication Date Title
CN106547687A (en) Application testing method, apparatus and system
CN109302522B (en) Test method, test device, computer system, and computer medium
CN111459794B (en) Communication network testing method, device, computer equipment and storage medium
CN105302732B (en) A kind of automatic test approach and device of mobile terminal
CN104407980B (en) Mobile solution automatic test device and method
US20170337116A1 (en) Application testing on different device types
CN108959068B (en) Software interface testing method, device and storage medium
CN111159049B (en) Automatic interface testing method and system
CN106649107B (en) Automatic testing method and device for stability of android system
US8855961B2 (en) Binary definition files
CN111124919A (en) User interface testing method, device, equipment and storage medium
US20150347281A1 (en) Automation testing using descriptive maps
CN103136095A (en) Method, device and system of test application program interface
CN105338110A (en) Remote debugging method, platform and server
KR20080068385A (en) Program test system, method and computer readable medium on which program for executing the method is recorded
CN107562637B (en) Method, device, system and storage medium for software testing
CN107357727A (en) APP testing results method, apparatus, readable storage medium storing program for executing and computer equipment
US20200050534A1 (en) System error detection
CN112463467A (en) Automated integrated test system and method thereof
CN111078547A (en) Automatic testing framework system for PYTHON general APP software
CN107844486B (en) Method and system for analyzing webpage problems for client
CN106713011A (en) Method and system for obtaining test data
CN110347565B (en) Application program abnormity analysis method and device and electronic equipment
KR101792864B1 (en) System and Method for verifying application
KR20150025106A (en) Verification apparatus, terminal device, system, method and computer-readable medium for monitoring of application verification result

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20170329

RJ01 Rejection of invention patent application after publication