CN112231206A - Script editing method for application program test, computer readable storage medium and test platform - Google Patents

Script editing method for application program test, computer readable storage medium and test platform Download PDF

Info

Publication number
CN112231206A
CN112231206A CN202011059886.9A CN202011059886A CN112231206A CN 112231206 A CN112231206 A CN 112231206A CN 202011059886 A CN202011059886 A CN 202011059886A CN 112231206 A CN112231206 A CN 112231206A
Authority
CN
China
Prior art keywords
script
test
application program
editing method
tester
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
CN202011059886.9A
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.)
Guangzhou Zhangdong Intelligent Technology Co ltd
Original Assignee
Guangzhou Zhangdong Intelligent Technology 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 Guangzhou Zhangdong Intelligent Technology Co ltd filed Critical Guangzhou Zhangdong Intelligent Technology Co ltd
Priority to CN202011059886.9A priority Critical patent/CN112231206A/en
Publication of CN112231206A publication Critical patent/CN112231206A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45504Abstract machines for programme code execution, e.g. Java virtual machine [JVM], interpreters, emulators
    • G06F9/45508Runtime interpretation or emulation, e g. emulator loops, bytecode interpretation
    • G06F9/45512Command shells

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The invention relates to the field of application program testing, in particular to a script editing method for application program testing, wherein after a tester accesses all devices to be tested into a control system and selects a manual operation device, a processor identifies the testing operation of the tester on the manual operation device and generates an executable script corresponding to the testing operation in a script recording window, when an element which is not recorded in the system and cannot be identified is encountered, the tester intercepts image information of the element and obtains the device execution operation after the element is executed, thereby establishing a script mapping record from the intercepted element to the device execution operation, providing a script editing method facing the system with the element which is not recorded in the system for the tester, and recording the script mapping in the script recording window as an executable script to be applied to other devices to be tested.

Description

Script editing method for application program test, computer readable storage medium and test platform
Technical Field
The invention relates to the field of application program testing, in particular to a script editing method for application program testing, a computer readable storage medium and a testing platform.
Background
In recent years, with the gradual popularization of mobile terminal devices such as smart phones and tablet computers, the mobile internet industry grows rapidly by means of the rapid development of networks and the support of powerful cloud services. The application of the mobile internet becomes an important means and mode for meeting the requirements of personal daily life and enterprise operation, and intelligent terminals such as mobile phones and tablets become an indispensable part of the life of people. The intelligent operating system is an important characteristic of powerful functions of the intelligent terminal, and the application program is used as core content for realizing the functions of the intelligent terminal and plays an increasingly important role in daily work and life of people. The concept of the application program is software which directly faces a user to provide certain functions, such as daily tool software like a browser/a map/WeChat, e-commerce software like Taobao/Jingdong, life service software like love art/buffalo, game software, and the like. Currently, the total amount of application software available for downloading in each large application store exceeds 300 thousands, and tens of thousands of application software are put on or off the shelf every day.
Currently, the main mobile terminal intelligent operating systems include the Android (Android) platform of Google and the iOS of apple company, when an application program is developed, software needs to be designed for different operating systems respectively, and intelligent terminals of different manufacturers and different models of the same manufacturer using the same intelligent operating system can run the same application program. Due to the diversity of mobile terminals, taking a mobile phone as an example, an application on a certain mobile phone platform works stably and normally, and the problems of flash back, black screen and the like of the application are often caused after the mobile phone is exchanged or an operating system is upgraded. Therefore, during the development process, before release and after version update, the application program needs to be tested on a specific hardware environment or even multiple real machines to find and correct various faults and defects existing in the application program, and ensure that the application program can stably run on multiple terminal machine types loaded with the same operating system. Common tests of applications include: interface tests, such as each button and its jump; functional tests, such as basic functional processes, data display verification (interface data); other tests, such as installation and uninstallation, interrupt testing, etc. Because the particularity of each application program, the test process and the test emphasis are different, the test is mainly performed through manual operation at present and is limited by the test period and the test cost, application developers (particularly small/original internet enterprises) can only select a few hot machine types of main equipment manufacturers to perform the test, the machine type coverage is small, and the probability of problems after the application programs are installed on untested machine types is high.
Due to the diversity of the application programs, each application program may be added with a unique function block in the development process, so that testers are required to perform manual testing and write related scripts for recording, however, new elements which are not recorded in the system are frequently encountered in the manual testing, and a script editor of the system cannot identify the new elements, so that the script recording fails, and the new elements need to be manually tested on each device to be tested in sequence, which wastes time and labor.
Disclosure of Invention
The purpose of the invention is: provided are a method capable of performing script editing with respect to a system non-written element, a computer-readable storage medium storing a program for implementing the method when executed by a processor, and a test platform using the medium, the test platform capable of providing a method of performing script editing when a tester faces the system non-written element.
A script editing method for application program test is provided, which comprises the following steps: executing test operation on an operation interface, and generating an executable script corresponding to the test operation in a script recording window;
the method also comprises a step of setting insertion screenshots, which is to execute the interception operation of the elements on the current operation interface, acquire the equipment execution operation after the elements are executed, establish script mapping records from the intercepted elements to the equipment execution operation, and record the script mapping records in a script recording window.
A computer-readable storage medium is also provided, the storage medium storing an executable computer program that, when executed by a processor, is capable of implementing the script editing method for application testing described above.
A test platform is also provided that includes a device cabinet having a plurality of device access ports pre-stored therein, an external display port, a processor controlling a plurality of devices accessed therein and a display interface accessing the external display port, and a computer readable storage medium having a computer program executable by the processor.
According to the script editing method for testing the application program, after a tester accesses all devices to be tested into a control system and selects a manual operation device, a processor identifies the test operation of the tester on the manual operation device, an executable script corresponding to the test operation is generated in a script recording window, when an element which is not recorded and can not be identified by the system is encountered, the tester intercepts image information of the element and obtains the device execution operation after the element is executed, so that a script mapping record from the intercepted element to the device execution operation is established, a script editing method facing the system when the element is not recorded is provided for the tester, and the script is mapped and recorded in the script recording window and is applied to other devices to be tested as an executable script.
Drawings
Fig. 1 is a schematic diagram of a connection relationship between an equipment cabinet and a display interface of a test platform system.
FIG. 2 is a schematic diagram of an automatic script entry interface in an operation interface of a test platform.
FIG. 3 is a schematic diagram of a script manual entry interface in an operation interface of the test platform.
Detailed Description
As shown in fig. 1, the equipment end of the test platform is a test cabinet equipped with N pieces of terminal equipment, and the operation end of the test platform is divided into a test cabinet with a display/operation interface integrated with the test cabinet and a cloud test platform with a display/operation interface and a test cabinet arranged independently according to different display modes. The cloud test platform can be additionally arranged in an independent controller, and can also be stored in a WEB terminal or installed on other terminals. A tester selects one mode of a cloud test platform or a test cabinet to test an application program of the mobile terminal, taking the cloud test platform of a WEB end as an example, after a user registers an account in a browser webpage, the user can randomly call resources within the authority range of the account, such as terminal equipment in a test cabinet, a test script library prestored in the test platform and the like.
The following description will take an example of a process in which a tester performs an application test on a certain application a installed on an Android device using a cloud test platform. And the tester opens the display interface to operate, and selects the android mobile phone or tablet model to be tested under the model selection directory. The cloud test platform system processor receives the machine type selection task instruction information and transmits the related instructions to the test cabinet, so that the port on the test cabinet, which is used for connecting the corresponding android mobile phone or the tablet, is correspondingly connected. The operation end of the cloud test platform system identifies test operation performed by a tester on the display interface, sends a test instruction to an instruction analysis tool prestored in corresponding equipment, the analysis tool executes a test according to the received instruction, and after all test cases are executed, the mobile phone end can obtain corresponding logs and feeds the logs back to the cloud test platform system in a reverse path mode.
In the testing process, the cloud testing platform system can quickly test the basic/conventional functions of the App based on the application program framework. The cloud test platform system automatically installs application programs (App) to be tested on all selected models, and compatibility test is carried out: and repeatedly executing the operations of installing, starting and uninstalling the application program on the mobile phones and the flat panels so as to test the compatibility of the App to different mobile phone and operating system versions. The cloud test platform system automatically calls a general test program to perform function test: and starting a basic test script of the application, and distinguishing whether the function and logic of the application are normal.
Due to the diversity of the application programs, each application program may be added with a unique function block in the development process, so that a tester needs to perform manual testing, traverse all execution tasks, and identify whether the application program can be completely executed and whether errors and bugs exist. At this time, the tester selects one of the devices to be tested (for example, the device to be tested 1) as the operating device, the user performs the test operation on the selected operating device on the display interface, and the cloud test platform system automatically and synchronously executes the same test operation on the other devices to be tested. The specific process of the multi-machine synchronous test of the cloud test platform system is as follows.
Referring to fig. 1, a tester clicks a "button" in an observation window 1 belonging to a device to be tested 1 in a display interface, the cloud test platform system controls the corresponding device to be tested 1 to execute the operation of clicking the "button", and meanwhile, the cloud test platform system controls other devices to be tested 2-n to synchronously execute the operation of clicking the "button". The processing process of the synchronous operation is realized through two ways, namely, directly positioning element buttons on the current interfaces of other devices to be tested 2-n, wherein the element buttons are the same as elements selected by a tester on an operation device, and the positioning mode is relatively conventional, so that common device interface elements in most application programs, such as searching, classification, mying, membership and the like, can be identified and positioned; the other positioning mode is to identify the position coordinates D (X, Y) of the operated element on the current interface of the current device, and directly convert the position coordinates D2(X2, Y2) -Dn (Xn, Yn) of the operated element on the other devices to be tested 2-n according to the dimensional proportional relation between the operating device 1 and the observation window 1 and the dimensional proportional relation between the other devices to be tested 2-n and the observation windows 2-n. Preferably, a certain weight is configured for the two positioning modes, and the two positioning modes of element positioning and coordinate positioning are performed synchronously to perform more accurate element and coordinate positioning. According to different models, different weights can be configured for each model, and specifically, the weight configuration of each model is obtained according to the accuracy of historical data.
According to the script editing method for the application program test, after a tester accesses all devices to be tested into the control system and selects the manual operation device, the cloud test platform system processor identifies the test operation of the tester on the manual operation device, positions the operation position of the tester and identifies the operation action executed by the tester, and controls other accessed devices to execute the same operation action at the same position. The control system can directly carry out the same test operation on other devices to be tested only by operating one device by a tester, thereby saving the test time and the test cost.
For the same application or the same series of application tests, part of the tests have similarity, so that a series of test processes need to be fixed in a script manner by a tester. The specific process of script editing is as follows, see fig. 2, before beginning to record the script, the system to be tested is opened first, click and begin to record the button, appear and inquire the dialog box, choose whether to record completely newly, click and confirm to enter and record; the left side of the page is an operation window used as an equipment display operation area, the right side of the page is a script recording window used as a script generation display area, a tester carries out test operation on the left side, for example, clicking a search box above the page, the script generation display area on the right side correspondingly generates an executable script 'clicking' the search box ', a test user inputs characters' in the search box and clicks search symbols in the search box, and the two test operations are sequentially and automatically generated and displayed as two executable scripts in the script generation display area; the test operation is recorded into an operation script until a test user clicks pause to pause script recording or clicks stop to stop recording the script and storing the script so as to call the related script in the subsequent test. Because new elements of the cloud test platform system and the like may be used in a newly developed application program, a script revision method is provided for testers, elements in the left lower corner of fig. 3 are in the same color and belong to new elements which are not stored in the cloud test platform system, the system cannot automatically recognize and generate a corresponding script, and at this time, a screenshot insertion setting step is performed. The insertion screenshot setting step specifically includes that a tester confirms an execution element intercepting operation, the interception is performed in the lower left corner of an equipment display operation area, the interception is performed in the corresponding element, the execution operation of the equipment is acquired after the element is clicked, a script which is established in the corresponding element page and is corresponding to the execution operation of the element is mapped and recorded as an executable script, and the script can be directly executed in the subsequent test operation without manual operation.
The method comprises the steps of recording a script of a cloud test platform system, particularly inserting a screenshot setting step, when a user tests any tested device in an operation window, automatically generating a script code by the script recording window, wherein the script code can be used for automatically testing other tested devices, and when a new element or other factors which can not automatically generate the script code are met, a tester can manually intercept the unidentified element for screenshot setting, so that an automatic test script is constructed, the script generation process is simple and visible, and the operation is convenient.
The cloud test platform system stores the script editing process as three files. The first is a script file which stores scripts in a script editor; the second is a parameter table file which is an excel table and all parameter data are stored in the excel table; the third is an object library file which is in an xml format, the object library information can be stored in the object library file, the object library can be edited, and the object library file can be stored after editing. The cloud test platform system is provided with a global variable and a check point, and after the global variable or the check point is set on a global variable and check point setting page, the test script can be automatically called when being generated, so that the operation is convenient.
In the whole application program testing process, the cloud testing platform system also records the application performance, such as starting time, reaction time, CPU occupancy rate, memory occupancy rate and the like, so as to evaluate the performance. And the cloud test platform system performs big data analysis on user data of the application program, wherein the big data analysis mainly comprises network conditions and hardware conditions, so that big data management is performed on the test process of the application program and big data analysis is performed on a test result.
The cloud test platform system packages the content of the test items after the test is completed, a packaging column is established on a display interface, the installation packages with the same name are automatically combined into the same item, and the versions are arranged according to the packaging (uploading) time sequence, so that a tester can manage the test process of the same type or the same series of application programs.

Claims (7)

1. The script editing method for the application program test comprises the following steps: executing test operation on an operation interface, and generating an executable script corresponding to the test operation in a script recording window;
the method is characterized by also comprising a step of setting an inserted screenshot, wherein the screenshot operation is executed on the current operation interface, the equipment execution operation after the element is executed is obtained, a script mapping record from the intercepted element to the equipment execution operation is established, and the script mapping record is recorded in a script recording window.
2. The script editing method for application program test according to claim 1, wherein said test operation is clicking a page element.
3. The script editing method for application program testing according to claim 2, wherein the executable script corresponding to the test operation of the clicked page element is an instruction for executing an action of clicking a page element.
4. The script editing method for application program testing according to claim 1, wherein in the step of inserting the screenshot, a step of recording a temporary instruction is included, which records the following temporary instruction in a script recording window: and executing the interception operation of the element on the current operation interface, and acquiring an instruction of executing the operation of the equipment after the element is executed.
5. The script editing method for application program testing as claimed in claim 4, wherein said temporary instruction is deleted from the script recording window after a script mapping record of the intercepted element to the device execution operation is created.
6. A computer-readable storage medium, in which a computer program is stored, wherein the computer program, when executed by a processor, is capable of implementing a script editing method for application testing according to any one of claims 1 to 5.
7. A test platform comprising an equipment rack having a plurality of equipment access ports pre-stored therein, an external display port, and a processor controlling the access of a plurality of equipment and a display interface accessing the external display port, further comprising a computer readable storage medium as claimed in claim 6, wherein a computer program stored on the computer readable storage medium is executable by the processor.
CN202011059886.9A 2020-09-30 2020-09-30 Script editing method for application program test, computer readable storage medium and test platform Pending CN112231206A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011059886.9A CN112231206A (en) 2020-09-30 2020-09-30 Script editing method for application program test, computer readable storage medium and test platform

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011059886.9A CN112231206A (en) 2020-09-30 2020-09-30 Script editing method for application program test, computer readable storage medium and test platform

Publications (1)

Publication Number Publication Date
CN112231206A true CN112231206A (en) 2021-01-15

Family

ID=74119801

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011059886.9A Pending CN112231206A (en) 2020-09-30 2020-09-30 Script editing method for application program test, computer readable storage medium and test platform

Country Status (1)

Country Link
CN (1) CN112231206A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114579028A (en) * 2022-03-03 2022-06-03 北京字节跳动网络技术有限公司 Interface screenshot method and device, computer equipment and storage medium
CN115237813A (en) * 2022-09-19 2022-10-25 平安银行股份有限公司 Script generation and test method, electronic device and computer storage medium
CN115865809A (en) * 2023-02-02 2023-03-28 爱集微咨询(厦门)有限公司 Data transmission method and device, electronic equipment and readable storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365779A (en) * 2013-07-09 2013-10-23 广东欧珀移动通信有限公司 Software test method and system
CN105740153A (en) * 2016-02-29 2016-07-06 网易(杭州)网络有限公司 Cloud testing method and device
CN107193750A (en) * 2017-07-04 2017-09-22 北京云测信息技术有限公司 A kind of script method for recording and device
CN109582566A (en) * 2018-11-01 2019-04-05 苏州蜗牛数字科技股份有限公司 A kind of script method for recording
CN109656643A (en) * 2017-10-10 2019-04-19 武汉斗鱼网络科技有限公司 More browser compatibility test methods, storage medium, electronic equipment and system
CN109871326A (en) * 2019-02-13 2019-06-11 广州云测信息技术有限公司 A kind of method and apparatus that script is recorded
CN110297758A (en) * 2019-05-20 2019-10-01 深圳壹账通智能科技有限公司 User interface automated testing method, device and computer readable storage medium
CN110297759A (en) * 2019-05-22 2019-10-01 深圳壹账通智能科技有限公司 A kind of method, apparatus making test page script, equipment and storage medium
CN111090577A (en) * 2019-10-12 2020-05-01 平安壹钱包电子商务有限公司 Multi-terminal synchronous testing method and device, computer equipment and storage medium

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103365779A (en) * 2013-07-09 2013-10-23 广东欧珀移动通信有限公司 Software test method and system
CN105740153A (en) * 2016-02-29 2016-07-06 网易(杭州)网络有限公司 Cloud testing method and device
CN107193750A (en) * 2017-07-04 2017-09-22 北京云测信息技术有限公司 A kind of script method for recording and device
CN109656643A (en) * 2017-10-10 2019-04-19 武汉斗鱼网络科技有限公司 More browser compatibility test methods, storage medium, electronic equipment and system
CN109582566A (en) * 2018-11-01 2019-04-05 苏州蜗牛数字科技股份有限公司 A kind of script method for recording
CN109871326A (en) * 2019-02-13 2019-06-11 广州云测信息技术有限公司 A kind of method and apparatus that script is recorded
CN110297758A (en) * 2019-05-20 2019-10-01 深圳壹账通智能科技有限公司 User interface automated testing method, device and computer readable storage medium
CN110297759A (en) * 2019-05-22 2019-10-01 深圳壹账通智能科技有限公司 A kind of method, apparatus making test page script, equipment and storage medium
CN111090577A (en) * 2019-10-12 2020-05-01 平安壹钱包电子商务有限公司 Multi-terminal synchronous testing method and device, computer equipment and storage medium

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114579028A (en) * 2022-03-03 2022-06-03 北京字节跳动网络技术有限公司 Interface screenshot method and device, computer equipment and storage medium
CN115237813A (en) * 2022-09-19 2022-10-25 平安银行股份有限公司 Script generation and test method, electronic device and computer storage medium
CN115865809A (en) * 2023-02-02 2023-03-28 爱集微咨询(厦门)有限公司 Data transmission method and device, electronic equipment and readable storage medium
CN115865809B (en) * 2023-02-02 2023-06-02 爱集微咨询(厦门)有限公司 Data transmission method, device, electronic equipment and readable storage medium

Similar Documents

Publication Publication Date Title
US11281570B2 (en) Software testing method, system, apparatus, device medium, and computer program product
CN105094783B (en) method and device for testing stability of android application
CN109302522B (en) Test method, test device, computer system, and computer medium
CN109840206B (en) Data testing method, device, terminal and storage medium
US10853232B2 (en) Adaptive system for mobile device testing
CN109885480B (en) Automatic interface compatibility testing method and device based on debugging bridge
CN112231206A (en) Script editing method for application program test, computer readable storage medium and test platform
WO2019227708A1 (en) Online debugging apparatus and method for test case, and computer-readable storage medium
CN105302722B (en) CTS automatic testing method and device
CN103984626A (en) Method and device for generating test-case script
CN115658529A (en) Automatic testing method for user page and related equipment
TWI476587B (en) Testing method and testing apparatus for testing function of electronic apparatus
CN116166525A (en) Method and device for generating test script
CN111651232A (en) One-machine multi-control method, device and system and electronic equipment
US11341030B2 (en) Scriptless software test automation
CN111414309B (en) Automatic test method of application program, computer equipment and storage medium
CN113127329B (en) Script debugging method and device and computer storage medium
CN112241373A (en) Automatic test method, test device, processor and test system
CN110825370B (en) Mobile terminal application development method, device and system
CN113986263A (en) Code automation test method, device, electronic equipment and storage medium
CN112231207A (en) Multi-machine testing method for application program testing, computer readable storage medium and testing platform
CN108536607B (en) UI test method, device and readable storage medium
CN110928798A (en) Code testing method, device and equipment
CN113608996B (en) Mirror image compiling test method, system, device and readable storage medium
KR20190129617A (en) Mobile app auto-test device

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20210115