WO2019114209A1 - 自动化测试分析方法、***、应用服务器及计算机可读存储介质 - Google Patents

自动化测试分析方法、***、应用服务器及计算机可读存储介质 Download PDF

Info

Publication number
WO2019114209A1
WO2019114209A1 PCT/CN2018/089424 CN2018089424W WO2019114209A1 WO 2019114209 A1 WO2019114209 A1 WO 2019114209A1 CN 2018089424 W CN2018089424 W CN 2018089424W WO 2019114209 A1 WO2019114209 A1 WO 2019114209A1
Authority
WO
WIPO (PCT)
Prior art keywords
software system
code
automated test
modified
system code
Prior art date
Application number
PCT/CN2018/089424
Other languages
English (en)
French (fr)
Inventor
熊星
Original Assignee
平安科技(深圳)有限公司
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 平安科技(深圳)有限公司 filed Critical 平安科技(深圳)有限公司
Publication of WO2019114209A1 publication Critical patent/WO2019114209A1/zh

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
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/368Test management for test version control, e.g. updating test cases to a new software version
    • 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/3692Test management for test results analysis

Definitions

  • the present application relates to the field of automated test analysis, and in particular, to an automated test analysis method, system, application server, and computer readable storage medium.
  • regression testing has a large workload in the entire software testing process. Multiple regression tests are performed at various stages of software development. In the progressive and rapid iterative development, the new version is continuously released. Make regression testing more frequent. However, in the case of regression testing, running a full-scale automated test usually results in large-scale errors. Usually, the cause is not a program bug, but the requirement or code change causes the test case to not be updated synchronously, resulting in a failure. With this increase in volume and time, the cost of automated automated case maintenance will become higher and higher, leading testers to slowly abandon automated testing.
  • the present application proposes an automated test analysis method, system, application server and computer readable storage medium, which enables a tester to evaluate whether an automated test foot needs to be modified according to an affected automated test script before performing regression testing.
  • the present application provides an automated test analysis method, which is applied to an application server, and the method includes:
  • the present application further provides an application server including a memory, a processor, and an automated test analysis system stored on the memory and operable on the processor, the automation
  • the test analysis system is implemented by the processor to implement the following steps:
  • the present application further provides an automated test analysis system, the automated test analysis system comprising:
  • the calling module is configured to retrieve the latest historical version code stored by the application server when receiving the tested software system code sent by the terminal device;
  • a comparison module configured to compare the tested software system code with the latest historical version code, and determine whether the tested software system code is modified
  • An analysis module configured to: when the tested software system code is modified, analyze the modified software system code to obtain all affected automated test scripts;
  • a feedback module configured to send the all affected automated test scripts to the terminal device.
  • the present application further provides a computer readable storage medium storing an automated test analysis system, the automated test analysis system being executable by at least one processor to enable The at least one processor performs the following steps:
  • the application server, the automated test analysis method, the system, and the computer readable storage medium proposed by the present application firstly retrieve the application server storage when receiving the tested software system code sent by the terminal device. a latest history version code; then comparing the software system code under test with the latest history version code to determine whether the software system code under test is modified; further, when the code of the software system under test is modified, analyzing All affected automated test scripts are obtained; finally, all of the affected automated test scripts are sent to the terminal device.
  • the regression test fails due to the modified software system code being modified, and can also obtain all the affected automated test scripts by analyzing the modified software system code to be tested, and Sending all the affected automated test scripts to the terminal device, so that the tester evaluates whether it is necessary to modify the automated test script before the regression test to improve the test efficiency.
  • FIG. 1 is a schematic diagram of an optional application environment of each embodiment of the present application.
  • FIG. 2 is a schematic diagram of an optional hardware architecture of the application server of FIG. 1;
  • FIG. 3 is a schematic diagram of a program module of a first embodiment of an automated test and analysis system of the present application
  • FIG. 4 is a schematic diagram of a program module of a second embodiment of the automated test and analysis system of the present application.
  • FIG. 5 is a schematic diagram of a program module of a third embodiment of the automated test and analysis system of the present application.
  • FIG. 6 is a schematic flow chart of a first embodiment of an automated test analysis method according to the present application.
  • FIG. 7 is a schematic flow chart of a second embodiment of an automated test analysis method according to the present application.
  • FIG. 8 is a schematic flow chart of a third embodiment of an automated test analysis method according to the present application.
  • Terminal Equipment 1 application server 2 The internet 3 Memory 11 processor 12 Network Interface 13 Automated test analysis system 200 Retrieve module 201 Comparison module 202 Analysis module 203 Feedback module 204 Positioning module 205 Setting module 206 Storage module 207 Sorting module 208
  • FIG. 1 it is a schematic diagram of an optional application environment of each embodiment of the present application.
  • the present application is applicable to an application environment including, but not limited to, the terminal device 1, the application server 2, and the network 3.
  • the terminal device 1 may be a mobile phone, a smart phone, a notebook computer, a digital broadcast receiver, a PDA (Personal Digital Assistant), a PAD (Tablet PC), a PMP (Portable Multimedia Player), a navigation device, or the like.
  • Mobile devices, as well as fixed terminals such as digital TVs, desktop computers, notebooks, servers, and the like.
  • the application server 2 may be a computing device such as a rack server, a blade server, a tower server, or a rack server.
  • the application server 2 may be a stand-alone server or a server cluster composed of multiple servers.
  • the network 3 may be an intranet, an Internet, a Global System of Mobile communication (GSM), a Wideband Code Division Multiple Access (WCDMA), a 4G network, Wireless or wired networks such as 5G networks, Bluetooth, Wi-Fi, etc.
  • GSM Global
  • the application server 2 is respectively connected to one or more of the terminal devices 1 through the network 3 for data transmission and interaction.
  • the application server 2 is installed and runs an automated test analysis system 200.
  • the application server 2 receives the tested software system code sent by the terminal device 1. Retrieving the latest historical version code stored by the application server; then comparing the measured software system code with the latest historical version code to determine whether the tested software system code is modified; further, when the The test software system code is modified to analyze all affected automated test scripts; finally, all of the affected automated test scripts are sent to the terminal device 1.
  • the regression test fails due to the modified software system code being modified, and can also obtain all the affected automated test scripts by analyzing the modified software system code to be tested, and Sending all the affected automated test scripts to the terminal device 1 so that the tester evaluates whether it is necessary to modify the automated test script before the regression test to improve the test efficiency.
  • the application server 2 may include, but is not limited to, the memory 11, the processor 12, and the network interface 13 being communicably connected to each other through a system bus. It is to be noted that FIG. 2 only shows the application server 2 with components 11-13, but it should be understood that not all illustrated components may be implemented, and more or fewer components may be implemented instead.
  • the memory 11 includes at least one type of readable storage medium including a flash memory, a hard disk, a multimedia card, a card type memory (eg, SD or DX memory, etc.), and a random access memory (RAM). , static random access memory (SRAM), read only memory (ROM), electrically erasable programmable read only memory (EEPROM), programmable read only memory (PROM), magnetic memory, magnetic disk, optical disk, and the like.
  • the memory 11 may be an internal storage unit of the application server 2, such as a hard disk or memory of the application server 2.
  • the memory 11 may also be an external storage device of the application server 2, such as a plug-in hard disk equipped on the application server 2, a smart memory card (SMC), and a secure digital number. (Secure Digital, SD) card, flash card, etc.
  • the memory 11 can also include both the internal storage unit of the application server 2 and its external storage device.
  • the memory 11 is generally used to store an operating system installed on the application server 2 and various types of application software, such as program codes of the automated test analysis system 200. Further, the memory 11 can also be used to temporarily store various types of data that have been output or are to be output.
  • the processor 12 may be a Central Processing Unit (CPU), controller, microcontroller, microprocessor, or other data processing chip in some embodiments.
  • the processor 12 is typically used to control the overall operation of the application server 2, such as performing control and processing related to data interaction or communication with the terminal device 1.
  • the processor 12 is configured to run program code or process data stored in the memory 11, such as running the automated test analysis system 200 or the like.
  • the network interface 13 may comprise a wireless network interface or a wired network interface, which is typically used to establish a communication connection between the application server 2 and other electronic devices.
  • the network interface 13 is mainly used to connect the application server 2 to one or more of the terminal devices 1 through the network 3, and the application server 2 and the one or more terminals. Establish a data transmission channel and communication connection between devices 1.
  • the present application proposes an automated test analysis system 200.
  • FIG. 3 it is a program module diagram of the first embodiment of the automated test analysis system 200 of the present application.
  • the automated test analysis system 200 includes a series of computer program instructions stored on the memory 11, and when the computer program instructions are executed by the processor 12, the automated test analysis operations of the embodiments of the present application can be implemented. .
  • automated test analysis system 200 can be divided into one or more modules based on the particular operations implemented by the various portions of the computer program instructions. For example, in FIG. 3, the automated test analysis system 200 can be segmented into a capture module 201, a comparison module 202, an analysis module 203, and a feedback module 204. among them:
  • the retrieving module 201 is configured to retrieve the latest historical version code stored by the application server when receiving the tested software system code sent by the terminal device 1.
  • the program code will be continually modified, or the program code of the new function will be added.
  • the program code will be continually modified, or the program code of the new function will be added.
  • you must re-test the existing features in order to confirm that the modified program code has been modified to not affect the existing functions, and verify that the intended purpose is achieved.
  • regression testing is usually required.
  • running a full-scale automated test usually results in large-scale errors.
  • the cause is not a program bug, but a requirement or code change, but the automated test script is not synchronized, resulting in a failure.
  • the application server 2 stores the software code of the tested software every time. Specifically, when the application server 2 receives the tested software system code submitted by the terminal device 1, the historical version code stored by the application server 2 is retrieved. In the present embodiment, the application server 2 retrieves the latest history version code.
  • the comparing module 202 is configured to compare the tested software system code with the latest historical version code to determine whether the tested software system code is modified.
  • the application server 2 analyzes the structural relationship between the tested software system code and the latest historical version code, including the calling relationship of the function and the method, the inclusion relationship of the structure, the inheritance relationship of the class, and the like, and further The place where the code has been modified.
  • the modification of the software system code under test includes the addition, deletion, and modification of functions.
  • the function is deleted; if a function does not exist in the historical version code, it exists in the software system code under test. , the function is a new function; if a function exists in both the object code and the historical version code, the white line character is filtered out by scanning the code line inside the function, and the character matching is compared. The same, the code has been changed, the function is modified.
  • the analyzing module 203 is configured to: when the tested software system code is modified, analyze the modified software system code to obtain all affected automated test scripts.
  • the feedback module 204 is configured to feed back all the affected automated test scripts to the terminal device 1.
  • the application server 2 sends the affected automated test script to the terminal device 1.
  • the tester can query the terminal device 1 to affect the automation due to the modified software system code being modified. Test the script so that you can evaluate whether you need to modify the automated test script before the regression test, keep the automated test script and the software code of the tested software system updated synchronously, and avoid the test failure because the automated test script does not update synchronously.
  • the application server 2 organizes all the affected automated test scripts into a chart or a report, generates an influence result graph, and feeds back the impact result graph to the terminal device 1 so that the tester can intuitively Learn about the affected automated test scripts.
  • the automated test analysis system 200 proposed by the present application firstly retrieves the latest historical version code stored by the application server 2 when receiving the software system code under test transmitted by the terminal device 1; Comparing the tested software system code with the latest historical version code to determine whether the tested software system code is modified; further, when the tested software system code is modified, analyzing all affected automated test scripts Finally, all of the affected automated test scripts are sent to the terminal device 1.
  • the regression test fails due to the modified software system code being modified, and can also obtain all the affected automated test scripts by analyzing the modified software system code to be tested, and Sending all the affected automated test scripts to the terminal device 1 so that the tester evaluates whether it is necessary to modify the automated test script before the regression test to improve the test efficiency.
  • the automated test and analysis system 200 further includes a positioning module 205, where
  • the retrieving module 201 is further configured to retrieve a mapping relationship between an automated test script pre-stored in the memory of the application server 2 and a function of the software system code under test;
  • the application server 2 automatically analyzes the mapping relationship between the automated test script and the software system code function, and saves the mapping relationship.
  • the mapping relationship is saved to the storage space of the application server 2.
  • the mapping relationship is retrieved from the storage space of the application server 2.
  • the positioning module 205 is configured to locate a mapping relationship between the modified function and the automated test script to obtain all the affected automated test scripts.
  • the application server 2 locates the modified function by using the positioning module 205. That is, the software system code function corresponding to the latest historical version corresponding to the modified function in the software system code, and determining the automation associated with the modified function according to the mapping relationship between the pre-saved software system code function and the automated test execution script. Test the execution script.
  • the automated test analysis system 200 can retrieve the mapping relationship between the automated test script pre-stored in the memory of the application server 2 and the function of the tested software system code, and locate To the mapping relationship between the modified function and the automated test script, all the affected automated test scripts are obtained, and all affected automated test scripts are quickly located to save time.
  • the automated test and analysis system 200 further includes a setting module 206, a storage module 207, and a sorting module 208, where:
  • the setting module 206 is configured to set a storage space.
  • the storage module 207 is configured to store the tested software system code sent from the terminal device 1.
  • the sorting module 208 sorts the test software system code according to the receiving time.
  • the application server 2 receives the tested software system code sent by the terminal device 1, the software module code to be tested is stored by the storage module 208. And each time the software system code to be tested is modified, the application server 2 retrieves the latest historical version of the tested software system code and compares the modified software system code to be tested. Therefore, in the embodiment, the application server 2 also sorts the test software system code according to the receiving time by the sorting module 209. The most recent receiving time is the latest historical version of the test software system code.
  • the automated test analysis system 200 proposed by the present application can also store the historical version of the tested software system code and sort them in chronological order, so that developers can better understand the software in development.
  • the present application also proposes an automated test analysis method.
  • FIG. 6 it is a schematic flowchart of the first embodiment of the automatic test analysis method of the present application.
  • the order of execution of the steps in the flowchart shown in FIG. 6 may be changed according to different requirements, and some steps may be omitted.
  • Step S301 when receiving the tested software system code sent by the terminal device 1, retrieve the latest historical version code stored by the application server 2.
  • the program code will be continually modified, or the program code of the new function will be added.
  • the program code will be continually modified, or the program code of the new function will be added.
  • you must re-test the existing features in order to confirm that the modified program code has been modified to not affect the existing functions, and verify that the intended purpose is achieved.
  • regression testing is usually required.
  • running a full-scale automated test usually results in large-scale errors.
  • the cause is not a program bug, but a requirement or code change, but the automated test script is not synchronized, resulting in a failure.
  • the application server 2 stores the software code of the tested software every time. Specifically, when the application server 2 receives the tested software system code submitted by the terminal device 1, the historical version code stored by the application server 2 is retrieved. In the present embodiment, the application server 2 retrieves the latest history version code.
  • Step S302 comparing the tested software system code with the latest historical version code to determine whether the tested software system code is modified.
  • the application server 2 analyzes the structural relationship between the tested software system code and the latest historical version code, including the calling relationship of the function and the method, the inclusion relationship of the structure, the inheritance relationship of the class, and the like, and further The place where the code has been modified.
  • the modification of the software system code under test includes the addition, deletion, and modification of functions.
  • the function is deleted; if a function does not exist in the historical version code, it exists in the software system code under test. , the function is a new function; if a function exists in both the object code and the historical version code, the white line character is filtered out by scanning the code line inside the function, and the character matching is compared. The same, the code has been changed, the function is modified.
  • Step S303 when the code of the tested software system is modified, analyzing the code of the tested software system to be modified to obtain all affected automated test scripts.
  • Step S304 feeding back all the affected automated test scripts to the terminal device 1.
  • the application server 2 sends the affected automated test script to the terminal device 1.
  • the tester can query the terminal device 1 to affect the automation due to the modified software system code being modified. Test the script so that you can evaluate whether you need to modify the automated test script before the regression test, keep the automated test script and the software code of the tested software system updated synchronously, and avoid the test failure because the automated test script does not update synchronously.
  • the application server 2 organizes all the affected automated test scripts into a chart or a report, generates an influence result graph, and feeds back the impact result graph to the terminal device 1 so that the tester can intuitively Learn about the affected automated test scripts.
  • the automated test analysis method proposed by the present application firstly, when receiving the tested software system code sent by the terminal device 1, retrieves the latest historical version code stored by the application server 2; Determining whether the software system code under test is modified; further, when the code of the software system under test is modified, analyzing all affected automated test scripts; Sending all the affected automated test scripts to the terminal device 1.
  • the regression test fails due to the modified software system code being modified, and can also obtain all the affected automated test scripts by analyzing the modified software system code to be tested, and Sending all the affected automated test scripts to the terminal device 1 so that the tester evaluates whether it is necessary to modify the automated test script before the regression test to improve the test efficiency.
  • FIG. 7 is a schematic flow chart of a second embodiment of the automated test analysis method of the present application.
  • the step of comparing the function logic branch of the source code with the test case logical branch pre-stored in the application server 2, before generating the function logic branch coverage report of the source code further includes the following step:
  • Step S401 retrieving a mapping relationship between an automated test script pre-stored in the memory of the application server 2 and a function of the software system code under test;
  • the application server 2 automatically analyzes the mapping relationship between the automated test script and the software system code function, and saves the mapping relationship.
  • the mapping relationship is saved to the storage space of the application server 2.
  • the mapping relationship is retrieved from the storage space of the application server 2.
  • Step S402 locating the mapping relationship between the modified function and the automated test script to obtain all the affected automated test scripts.
  • the application server 2 locates the modified function through the positioning module 206. That is, the software system code function corresponding to the latest historical version corresponding to the modified function in the software system code, and determining the automation associated with the modified function according to the mapping relationship between the pre-saved software system code function and the automated test execution script. Test the execution script.
  • the automated test analysis method proposed by the present application can retrieve the mapping relationship between the automated test script pre-stored in the memory of the application server 2 and the function of the tested software system code, and Locating the mapping relationship between the modified function and the automated test script, obtaining all the affected automated test scripts, and quickly locating all affected automated test scripts, saving time.
  • the step of generating the function logic branch coverage report of the source code includes:
  • step S501 a storage space is set.
  • Step S502 storing the software system code under test transmitted from the terminal device 1.
  • Step S503 sorting the test software system code according to the receiving time.
  • the application server 2 when the application server 2 receives the software system code under test sent by the terminal device 1, the application server 2 stores the software system code under test. And each time the software system code to be tested is modified, the application server 2 retrieves the latest historical version of the tested software system code and compares the modified software system code to be tested. Therefore, in the embodiment, the application server 2 sorts the test software system codes according to the reception time. The most recent receiving time is the latest historical version of the test software system code.
  • the automated test analysis method proposed by the present application can also store the historical version of the tested software system code and sort them in chronological order, so that developers can better understand the evolution of the software in development.
  • the procedure and the program code of the reference historical version can also store the historical version of the tested software system code and sort them in chronological order, so that developers can better understand the evolution of the software in development.
  • the foregoing embodiment method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be through hardware, but in many cases, the former is better.
  • Implementation Based on such understanding, the technical solution of the present application, which is essential or contributes to the prior art, may be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk,
  • the optical disc includes a number of instructions for causing a terminal device (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) to perform the methods described in various embodiments of the present application.

Landscapes

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

Abstract

本申请公开了一种自动化测试分析方法,该方法包括:当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;比较被测软件***代码与所述最新历史版本代码,确定被测软件***代码是否被修改;当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;将所有受影响的自动化测试脚本发送至所述终端设备。本申请还提供一种自动化测试分析***、应用服务器及计算机可读存储介质。本申请提供的自动化测试分析方法、***、应用服务器及计算机可读存储介质可以使得测试人员在进行回归测试之前根据受影响的自动化测试脚本评估是否需要修改自动化测试脚本,提高测试效率。

Description

自动化测试分析方法、***、应用服务器及计算机可读存储介质
优先权申明
本申请基于巴黎公约申明享有2017年12月15日递交的申请号为CN 201711344740.7、名称为“自动化测试分析方法、应用服务器及计算机可读存储介质”中国专利申请的优先权,该中国专利申请的整体内容以参考的方式结合在本申请中。
技术领域
本申请涉及自动化测试分析领域,尤其涉及一种自动化测试分析方法、***、应用服务器及计算机可读存储介质。
背景技术
回归测试作为软件生命周期的一个组成部分,在整个软件测试过程中占有很大的工作量比重,软件开发的各个阶段都会进行多次回归测试,在渐进和快速迭代开发中,新版本的连续发布使回归测试进行的更加频繁。然而在回归测试的时候,运行全量自动化测试通常会出现大面积的错误,而通常发现原因并不是程序bug,而是需求或者代码变更导致测试案例没有同步更新,导致运行失败。随着这种量的加大以及时间关系,慢慢的自动化案例维护成本会越来越高,导致测试人员慢慢开始放弃自动化测试。
发明内容
有鉴于此,本申请提出一种自动化测试分析方法、***、应用服务器及计算机可读存储介质,能够使得测试人员在进行回归测试之前根据受影响的自动化测试脚本评估是否需要修改自动化测试脚。
首先,为实现上述目的,本申请提出一种自动化测试分析方法,该方法应用于应用服务器,所述方法包括:
当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
当所述被测软件***代码被修改,分析被修改的所述被测软件***代码 以得到所有受影响自动化测试脚本;
将所述所有受影响的自动化测试脚本发送至所述终端设备。
此外,为实现上述目的,本申请还提供一种应用服务器,所述应用服务器包括存储器、处理器及存储在所述存储器上并可在所述处理器上运行的自动化测试分析***,所述自动化测试分析***被所述处理器执行时实现如下步骤:
当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
将所述所有受影响的自动化测试脚本发送至所述终端设备。
此外,为实现上述目的,本申请还提供一种自动化测试分析***,所述自动化测试分析***包括:
调取模块,用于当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
比较模块,用于比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
分析模块,用于当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
反馈模块,用于将所述所有受影响的自动化测试脚本发送至所述终端设备。
进一步地,为实现上述目的,本申请还提供一种计算机可读存储介质,所述计算机可读存储介质存储有自动化测试分析***,所述自动化测试分析***可被至少一个处理器执行,以使所述至少一个处理器执行如下步骤:
当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的 最新历史版本代码;
比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
将所述所有受影响的自动化测试脚本发送至所述终端设备。
相较于现有技术,本申请所提出的应用服务器、自动化测试分析方法、***及计算机可读存储介质,首先,当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;然后,比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;进一步地,当所述被测软件***代码被修改,分析得到所有受影响自动化测试脚本;最后,将所述所有受影响的自动化测试脚本发送至所述终端设备。这样,既可以避免现有技术中通过因被测软件***代码被修改而导致回归测试失败的缺陷,也可以通过分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本,并将所述所有受影响的自动化测试脚本发送至所述终端设备,使得测试人员在进行回归测试之前评估是否需要修改自动化测试脚本,提高测试效率。
附图说明
图1是本申请各个实施例一可选的应用环境示意图;
图2是图1中应用服务器一可选的硬件架构的示意图;
图3是本申请自动化测试分析***第一实施例的程序模块示意图;
图4是本申请自动化测试分析***第二实施例的程序模块示意图;
图5是本申请自动化测试分析***第三实施例的程序模块示意图;
图6为本申请自动化测试分析方法第一实施例的流程示意图;
图7为本申请自动化测试分析方法第二实施例的流程示意图;
图8为本申请自动化测试分析方法第三实施例的流程示意图。
附图标记:
终端设备 1
应用服务器 2
网络 3
存储器 11
处理器 12
网络接口 13
自动化测试分析*** 200
调取模块 201
比较模块 202
分析模块 203
反馈模块 204
定位模块 205
设定模块 206
存储模块 207
排序模块 208
本申请目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处所描述的具体实施例仅用以解释本申请,并不用于限定本申请。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
需要说明的是,在本申请中涉及“第一”、“第二”等的描述仅用于描述目的,而不能理解为指示或暗示其相对重要性或者隐含指明所指示的技术特征的数 量。由此,限定有“第一”、“第二”的特征可以明示或者隐含地包括至少一个该特征。另外,各个实施例之间的技术方案可以相互结合,但是必须是以本领域普通技术人员能够实现为基础,当技术方案的结合出现相互矛盾或无法实现时应当认为这种技术方案的结合不存在,也不在本申请要求的保护范围之内。
参阅图1所示,是本申请各个实施例一可选的应用环境示意图。
在本实施例中,本申请可应用于包括,但不仅限于,终端设备1、应用服务器2、网络3的应用环境中。其中,所述终端设备1可以是移动电话、智能电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、导航装置等等的可移动设备,以及诸如数字TV、台式计算机、笔记本、服务器等等的固定终端。所述应用服务器2可以是机架式服务器、刀片式服务器、塔式服务器或机柜式服务器等计算设备,该应用服务器2可以是独立的服务器,也可以是多个服务器所组成的服务器集群。所述网络3可以是企业内部网(Intranet)、互联网(Internet)、全球移动通讯***(Global System of Mobile communication,GSM)、宽带码分多址(Wideband Code Division Multiple Access,WCDMA)、4G网络、5G网络、蓝牙(Bluetooth)、Wi-Fi等无线或有线网络。
其中,所述应用服务器2中通过所述网络3分别与一个或多个所述终端设备1通信连接,以进行数据传输和交互。
本实施例中,所述应用服务器2内安装并运行有自动化测试分析***200,当所述自动化测试分析***200运行时,所述应用服务器2当接收到终端设备1发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;然后,比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;进一步地,当所述被测软件***代码被修改,分析得到所有受影响自动化测试脚本;最后,将所述所有受影响的自动化测试脚本发送至所述终端设备1。这样,既可以避免现有技术中通过因被测软件***代码被修改而导致回归测试失败的缺陷,也可以通过分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本,并将所述所有受影响的自动化测试脚本发送至所述终端设备1,使得测试人员在进行回归测试之前评 估是否需要修改自动化测试脚本,提高测试效率。
参阅图2所示,是图1中应用服务器2一可选的硬件架构的示意图。本实施例中,所述应用服务器2可包括,但不仅限于,可通过***总线相互通信连接存储器11、处理器12、网络接口13。需要指出的是,图2仅示出了具有组件11-13的应用服务器2,但是应理解的是,并不要求实施所有示出的组件,可以替代的实施更多或者更少的组件。
其中,所述存储器11至少包括一种类型的可读存储介质,所述可读存储介质包括闪存、硬盘、多媒体卡、卡型存储器(例如,SD或DX存储器等)、随机访问存储器(RAM)、静态随机访问存储器(SRAM)、只读存储器(ROM)、电可擦除可编程只读存储器(EEPROM)、可编程只读存储器(PROM)、磁性存储器、磁盘、光盘等。在一些实施例中,所述存储器11可以是所述应用服务器2的内部存储单元,例如该应用服务器2的硬盘或内存。在另一些实施例中,所述存储器11也可以是所述应用服务器2的外部存储设备,例如该应用服务器2上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。当然,所述存储器11还可以既包括所述应用服务器2的内部存储单元也包括其外部存储设备。本实施例中,所述存储器11通常用于存储安装于所述应用服务器2的操作***和各类应用软件,例如所述自动化测试分析***200的程序代码等。此外,所述存储器11还可以用于暂时地存储已经输出或者将要输出的各类数据。
所述处理器12在一些实施例中可以是中央处理器(Central Processing Unit,CPU)、控制器、微控制器、微处理器、或其他数据处理芯片。该处理器12通常用于控制所述应用服务器2的总体操作,例如执行与所述终端设备1进行数据交互或者通信相关的控制和处理等。本实施例中,所述处理器12用于运行所述存储器11中存储的程序代码或者处理数据,例如运行所述的自动化测试分析***200等。
所述网络接口13可包括无线网络接口或有线网络接口,该网络接口13通常用于在所述应用服务器2与其他电子设备之间建立通信连接。本实施例中,所述网络接口13主要用于通过所述网络3将所述应用服务器2与一个或多个所述终端设备1相连,在所述应用服务器2与所述一个或多个终端设备1 之间的建立数据传输通道和通信连接。
至此,己经详细介绍了本申请各个实施例的应用环境和相关设备的硬件结构和功能。下面,将基于上述应用环境和相关设备,提出本申请的各个实施例。
首先,本申请提出一种自动化测试分析***200。
参阅图3所示,是本申请自动化测试分析***200第一实施例的程序模块图。
本实施例中,所述自动化测试分析***200包括一系列的存储于存储器11上的计算机程序指令,当该计算机程序指令被处理器12执行时,可以实现本申请各实施例的自动化测试分析操作。在一些实施例中,基于该计算机程序指令各部分所实现的特定的操作,自动化测试分析***200可以被划分为一个或多个模块。例如,在图3中,所述自动化测试分析***200可以被分割成调取模块201、比较模块202、分析模块203、以及反馈模块204。其中:
所述调取模块201,用于当接收到终端设备1发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码。
通常地,在软件开发的过程中,一定会不断的修改程序代码,或是增加新功能的程序代码。每次更改程序代码,则意味着软件变更,就必须重新测试现有功能,以便确认改程序代码被修改后由没有影响到既有功能,并验证是否达到预期的目的。为了验证程序代码修改的正确性及其影响,通常需要进行回归测试。然而在回归测试的时候,运行全量自动化测试通常会出现大面积的错误,而通常发现原因并不是程序bug,而是需求或者代码变更,但是自动化测试脚本没有同步更新,从而导致运行失败。
因此,在本实施例中,所述应用服务器2存储每一次修改被测软件***代码。具体地,当应用服务器2接收到终端设备1提交的被测软件***代码时,调取所述应用服务器2存储的历史版本代码。在本实施方式中,应用服务器2调取最新历史版本代码。
所述比较模块202,用于比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改。
具体地,所述应用服务器2对所述被测软件***代码与所述最新历史版 本代码的结构关系进行分析,包括函数及方法的调用关系、结构的包含关系、类的继承关系等,进而找出代码中做过修改的地方。
在本实施方式中,被测软件***代码的修改包括函数的增加、删除、修改。详细而言,如果一个函数在历史版本代码中存在而在被测软件***代码中不存在,则说明该函数被删除;如果一个函数在历史版本代码中不存在而在被测软件***代码中存在,则说明该函数是新增函数;如果一个函数在被测对象代码和历史版本代码中都存在,则通过扫描函数内代码行,过滤掉空白字符,进行字符匹配对比,如果出现函数内代码不相同,则说明代码有改动,该函数被修改。
所述分析模块203,用于当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本。
具体地,从上文可知,在回归测试的时候,运行全量自动化测试通常会出现大面积的错误,而通常发现原因并不是程序bug,而是需求或者被测软件***代码被修改,但是自动化测试脚本没有同步更新,从而导致运行失败。因此,当所述应用服务器2在确定所述被测软件***代码被修改时,分析所述被修改的函数,根据被修改的函数与自动化测试脚本的关联关系,确定该被修改的函数将会影响到的自动化测试脚本。
所述反馈模块204,用于将所述所有受影响的自动化测试脚本反馈至所述终端设备1。
具体地,所述应用服务器2将所述受影响的自动化测试脚本发送至所述终端设备1,测试员在进行回归测试之前可以通过终端设备1查询因被测软件***代码被修改而影响到自动化测试脚本,从而可以在回归测试之前评估是否需要修改自动化测试脚本,保持自动化测试脚本与被测软件***代码的同步更新,避免因自动化测试脚本没有同步更新,而导致测试失败。
在本实施例中,所述应用服务器2将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图并将所述影响结果图反馈至所述终端设备1,使得测试员可以直观地了解受影响的自动化测试脚本。
通过上述程序模块201-204,本申请所提出的自动化测试分析***200,首先,当接收到终端设备1发送的被测软件***代码时,调取应用服务器2 存储的最新历史版本代码;然后,比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;进一步地,当所述被测软件***代码被修改,分析得到所有受影响自动化测试脚本;最后,将所述所有受影响的自动化测试脚本发送至所述终端设备1。这样,既可以避免现有技术中通过因被测软件***代码被修改而导致回归测试失败的缺陷,也可以通过分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本,并将所述所有受影响的自动化测试脚本发送至所述终端设备1,使得测试人员在进行回归测试之前评估是否需要修改自动化测试脚本,提高测试效率。
进一步地,基于本申请自动化测试分析***200的上述第一实施例,提出本申请的第二实施例(如图4所示)。本实施例中,所述自动化测试分析***200还包括定位模块205,其中,
所述调取模块201,还用于调取预存储在所述应用服务器2内存中的自动化测试脚本与被测软件***代码的函数之间的映射关系;
具体地,在进行自动化测试期间,所述应用服务器2自动分析自动化测试脚本与软件***代码函数之间的映射关系,并保存所述映射关系。在本实施例中,所述映射关系保存至所述应用服务器2的存储空间。当被测软件***代码被修改时,从所述应用服务器2的存储空间调取所述映射关系。
所述定位模块205,用于定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
具体地,若分析出该软件***的软件代码被修改如有新增代码、修改代码、删除代码等情况时,所述应用服务器2通过所述定位模块205定位到所述该被修改的函数也即该软件***代码中修改后的函数相对应的最新历史版本的软件***代码函数,并根据预先保存的软件***代码函数与自动化测试执行脚本的映射关系,确定该被修改的函数相关联的自动化测试执行脚本。
通过上述程序模块205,本申请所提出的自动化测试分析***200可以通过调取预存储在所述应用服务器2内存中的自动化测试脚本与被测软件***代码的函数之间的映射关系,并定位到所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本,实现快速定位所有受影响自动化测试脚本,节省时间。
进一步地,基于本申请自动化测试分析***200的上述第一实施例,提出本申请的第三实施例(如图5所示)。本实施例中,所述的自动化测试分析***200还包括设定模块206,存储模块207以及排序模块208,其中:
所述设定模块206,用于设定一个存储空间。
所述存储模块207,用于存储从终端设备1发送的被测软件***代码。
所述排序模块208,按照接收时间对所述测试软件***代码进行排序。
具体地,从上文可知,在软件开发的过程中,无可避免的会不断的修改程序代码,或是增加新功能的程序代码。为了让开发人员更好地了解软件在开发中的要演进过程以及参考历史版本的程序代码。在本实施例中,当所述应用服务器2接收到终端设备1发送的被测软件***代码时,通过存储模块208存储所述被测软件***代码。而每次被测试软件***代码被修改后,所述应用服务器2调取最新历史版本的被测软件***代码与所述修改后的被测软件***代码进行比较。因此,在本实施例中,所述应用服务器2还通过排序模块209按照接收时间对所述所述测试软件***代码进行排序。接收时间最靠前的为最新历史版本的测试软件***代码。
通过上述程序模块206-208,本申请所提出的自动化测试分析***200,还能够在存储历史版本的被测软件***代码,并按照时间顺序排序,方便开发人员更好地了解软件在开发中的要演进过程以及参考历史版本的程序代码。
此外,本申请还提出一种自动化测试分析方法。
参阅图6所示,是本申请自动化测试分析方法第一实施例的流程示意图。在本实施例中,根据不同的需求,图6所示的流程图中的步骤的执行顺序可以改变,某些步骤可以省略。
步骤S301,当接收到终端设备1发送的被测软件***代码时,调取应用服务器2存储的最新历史版本代码。
通常地,在软件开发的过程中,一定会不断的修改程序代码,或是增加新功能的程序代码。每次更改程序代码,则意味着软件变更,就必须重新测试现有功能,以便确认改程序代码被修改后由没有影响到既有功能,并验证 是否达到预期的目的。为了验证程序代码修改的正确性及其影响,通常需要进行回归测试。然而在回归测试的时候,运行全量自动化测试通常会出现大面积的错误,而通常发现原因并不是程序bug,而是需求或者代码变更,但是自动化测试脚本没有同步更新,从而导致运行失败。
因此,在本实施例中,所述应用服务器2存储每一次修改被测软件***代码。具体地,当应用服务器2接收到终端设备1提交的被测软件***代码时,调取所述应用服务器2存储的历史版本代码。在本实施方式中,应用服务器2调取最新历史版本代码。
步骤S302,比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改。
具体地,所述应用服务器2对所述被测软件***代码与所述最新历史版本代码的结构关系进行分析,包括函数及方法的调用关系、结构的包含关系、类的继承关系等,进而找出代码中做过修改的地方。
在本实施方式中,被测软件***代码的修改包括函数的增加、删除、修改。详细而言,如果一个函数在历史版本代码中存在而在被测软件***代码中不存在,则说明该函数被删除;如果一个函数在历史版本代码中不存在而在被测软件***代码中存在,则说明该函数是新增函数;如果一个函数在被测对象代码和历史版本代码中都存在,则通过扫描函数内代码行,过滤掉空白字符,进行字符匹配对比,如果出现函数内代码不相同,则说明代码有改动,该函数被修改。
步骤S303,当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本。
具体地,从上文可知,在回归测试的时候,运行全量自动化测试通常会出现大面积的错误,而通常发现原因并不是程序bug,而是需求或者被测软件***代码被修改,但是自动化测试脚本没有同步更新,从而导致运行失败。因此,当所述应用服务器2在确定所述被测软件***代码被修改时,分析所述被修改的函数,根据被修改的函数与自动化测试脚本的关联关系,确定该被修改的函数将会影响到的自动化测试脚本。
步骤S304,将所述所有受影响的自动化测试脚本反馈至所述终端设备1。
具体地,所述应用服务器2将所述受影响的自动化测试脚本发送至所述 终端设备1,测试员在进行回归测试之前可以通过终端设备1查询因被测软件***代码被修改而影响到自动化测试脚本,从而可以在回归测试之前评估是否需要修改自动化测试脚本,保持自动化测试脚本与被测软件***代码的同步更新,避免因自动化测试脚本没有同步更新,而导致测试失败。
在本实施例中,所述应用服务器2将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图并将所述影响结果图反馈至所述终端设备1,使得测试员可以直观地了解受影响的自动化测试脚本。
通过上述步骤S301-304,本申请所提出的自动化测试分析方法,首先,当接收到终端设备1发送的被测软件***代码时,调取应用服务器2存储的最新历史版本代码;然后,比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;进一步地,当所述被测软件***代码被修改,分析得到所有受影响自动化测试脚本;最后,将所述所有受影响的自动化测试脚本发送至所述终端设备1。这样,既可以避免现有技术中通过因被测软件***代码被修改而导致回归测试失败的缺陷,也可以通过分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本,并将所述所有受影响的自动化测试脚本发送至所述终端设备1,使得测试人员在进行回归测试之前评估是否需要修改自动化测试脚本,提高测试效率。
进一步地,基于本申请自动化测试分析方法的上述第一实施例,提出本申请自动化测试分析方法的第二实施例。
如图7所示,是本申请自动化测试分析方法第二实施例的流程示意图。本实施例中,所述将所述源代码的功能逻辑分支与预存储在应用服务器2的测试案例逻辑分支进行比较,生成所述源代码的功能逻辑分支覆盖率报告的步骤之前,还包括如下步骤:
步骤S401,调取预存储在所述应用服务器2内存中的自动化测试脚本与被测软件***代码的函数之间的映射关系;
具体地,在进行自动化测试期间,所述应用服务器2自动分析自动化测试脚本与软件***代码函数之间的映射关系,并保存所述映射关系。在本实施例中,所述映射关系保存至所述应用服务器2的存储空间。当被测软件***代码被修改时,从所述应用服务器2的存储空间调取所述映射关系。
步骤S402,定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
具体地,若分析出该软件***的软件代码被修改如有新增代码、修改代码、删除代码等情况时,所述应用服务器2通过所述定位模块206定位到所述该被修改的函数也即该软件***代码中修改后的函数相对应的最新历史版本的软件***代码函数,并根据预先保存的软件***代码函数与自动化测试执行脚本的映射关系,确定该被修改的函数相关联的自动化测试执行脚本。
通过上述步骤S401-S402,本申请所提出的自动化测试分析方法,可以通过调取预存储在所述应用服务器2内存中的自动化测试脚本与被测软件***代码的函数之间的映射关系,并定位到所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本,实现快速定位所有受影响自动化测试脚本,节省时间。
进一步地,基于本申请自动化测试分析方法的上述第一和第二实施例,提出本申请自动化测试分析方法的第三实施例。
如图8所示,是本申请自动化测试分析方法第三实施例的流程示意图。本实施例中,所述生成所述源代码的功能逻辑分支覆盖率报告的步骤,具体包括:
步骤S501,设定一个存储空间。
步骤S502,存储从终端设备1发送的被测软件***代码。
步骤S503,按照接收时间对所述测试软件***代码进行排序。
具体地,从上文可知,在软件开发的过程中,无可避免的会不断的修改程序代码,或是增加新功能的程序代码。为了让开发人员更好地了解软件在开发中的要演进过程以及参考历史版本的程序代码。在本实施例中,当所述应用服务器2接收到终端设备1发送的被测软件***代码时,所述应用服务器2存储所述被测软件***代码。而每次被测试软件***代码被修改后,所述应用服务器2调取最新历史版本的被测软件***代码与所述修改后的被测软件***代码进行比较。因此,在本实施例中,所述应用服务器2按照接收时间对所述测试软件***代码进行排序。接收时间最靠前的为最新历史版本的测试软件***代码。
通过上述步骤S501-S503,本申请所提出的自动化测试分析方法,还能够在存储历史版本的被测软件***代码,并按照时间顺序排序,方便开发人员更好地了解软件在开发中的要演进过程以及参考历史版本的程序代码。
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本申请各个实施例所述的方法。
以上仅为本申请的优选实施例,并非因此限制本申请的专利范围,凡是利用本申请说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本申请的专利保护范围内。

Claims (20)

  1. 一种自动化测试分析方法,应用于应用服务器,其特征在于,所述方法包括:
    当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
    比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
    当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
    将所述所有受影响的自动化测试脚本发送至所述终端设备。
  2. 如权利要求1所述的自动化测试分析方法,其特征在于,所述根据所述被修改的函数与自动化测试脚本的映射关系,确定所有受影响自动化测试脚本的步骤,具体包括如下步骤:
    调取与存储在所述应用服务器中的所述自动化测试脚本与被测软件***代码的函数之间的映射关系;
    定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
  3. 如权利要求1所述的自动化测试分析方法,其特征在于,所述当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码的步骤之前,还包括如下步骤:
    设定一个存储空间;
    存储从终端设备发送的测软件***代码;
    按照接收时间对所述测试软件***代码进行排序,其中,接收时间最靠前的为最新历史版本的测试软件***代码。
  4. 如权利要求1所述的自动化测试分析方法,其特征在于,所述比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改的步骤,具体包括:
    分析被测软件***代码与所述最新历史版本代码的结构关系;
    根据所述结构关系,判断被测软件***代码是否被修改,其中,所述结构关系为函数及方法的调用关系、结构的包含关系、类的继承关系。
  5. 如权利要求1-4任一项所述的自动化测试分析方法,其特征在于,所述将所述所有受影响的自动化测试脚本发送至所述终端设备的步骤,具体包括:
    将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图;
    将所述影响结果图反馈至所述终端设备。
  6. 一种应用服务器,其特征在于,所述应用服务器包括存储器、处理器,所述存储器上存储有可在所述处理器上运行的自动化测试分析***,所述自动化测试分析***被所述处理器执行时实现如下步骤:
    当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
    比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
    当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
    将所述所有受影响的自动化测试脚本发送至所述终端设备。
  7. 如权利要求6所述的应用服务器,其特征在于,所述根据所述被修改的函数与自动化测试脚本的映射关系,确定所有受影响自动化测试脚本的步骤,具体包括如下步骤:
    调取与存储在所述应用服务器中的所述自动化测试脚本与被测软件***代码的函数之间的映射关系;
    定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
  8. 如权利要求6所述的应用服务器,其特征在于,所述当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码的步骤之前,还包括如下步骤:
    设定一个存储空间;
    存储从终端设备发送的测软件***代码;
    按照接收时间对所述测试软件***代码进行排序,其中,接收时间最靠前的为最新历史版本的测试软件***代码。
  9. 如权利要求6所述的应用服务器,其特征在于,所述比较所述被测软 件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改的步骤,具体包括:
    分析被测软件***代码与所述最新历史版本代码的结构关系;
    根据所述结构关系,判断被测软件***代码是否被修改,其中,所述结构关系为函数及方法的调用关系、结构的包含关系、类的继承关系。
  10. 如权利要求5-9所述的应用服务器,其特征在于,所述将所述所有受影响的自动化测试脚本发送至所述终端设备的步骤,具体包括:
    将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图;
    将所述影响结果图反馈至所述终端设备。
  11. 一种自动化测试分析***,其特征在于,所述自动化测试分析***包括:
    调取模块,用于当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
    比较模块,用于比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
    分析模块,用于当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
    反馈模块,用于将所述所有受影响的自动化测试脚本发送至所述终端设备。
  12. 如权利要求11所述的自动化测试分析***,其特征在于,所述调取模块还用于:
    调取与存储在所述应用服务器中的所述自动化测试脚本与被测软件***代码的函数之间的映射关系;
    所述自动化测试分析***还包括定位模块,所述定位模块用于:
    定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
  13. 如权利要求11所述的自动化测试分析***,其特征在于,所述自动化测试分析***,还包括:
    设定模块,用于设定一个存储空间;
    存储模块,用于存储从终端设备发送的测软件***代码;
    排序模块,用于按照接收时间对所述测试软件***代码进行排序,其中,接收时间最靠前的为最新历史版本的测试软件***代码。
  14. 如权利要求11所述的自动化测试分析***,其特征在于,所述比较模块,具体用于:
    分析被测软件***代码与所述最新历史版本代码的结构关系;
    根据所述结构关系,判断被测软件***代码是否被修改,其中,所述结构关系为函数及方法的调用关系、结构的包含关系、类的继承关系。
  15. 如权利要求11-14任一项所述的自动化测试分析***,其特征在于,所述反馈模块,具体用于:
    将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图;
    将所述影响结果图反馈至所述终端设备。
  16. 一种计算机可读存储介质,其特征在于,所述计算机可读存储介质存储有自动化测试分析***,所述自动化测试分析***可被至少一个处理器执行,以使所述至少一个处理器执行如下步骤:
    当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史版本代码;
    比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改;
    当所述被测软件***代码被修改,分析被修改的所述被测软件***代码以得到所有受影响自动化测试脚本;
    将所述所有受影响的自动化测试脚本发送至所述终端设备。
  17. 如权利要求16所述的计算机可读存储介质,其特征在于,所述根据所述被修改的函数与自动化测试脚本的映射关系,确定所有受影响自动化测试脚本的步骤,具体包括如下步骤:
    调取与存储在所述应用服务器中的所述自动化测试脚本与被测软件***代码的函数之间的映射关系;
    定位所述被修改的函数与所述自动化测试脚本的映射关系,得到所述所有受影响自动化测试脚本。
  18. 如权利要求16所述的计算机可读存储介质,其特征在于,所述当接收到终端设备发送的被测软件***代码时,调取应用服务器存储的最新历史 版本代码的步骤之前,所述处理器还用于执行自动化测试分析***,以实现如下步骤:
    设定一个存储空间;
    存储从终端设备发送的测软件***代码;
    按照接收时间对所述测试软件***代码进行排序,其中,接收时间最靠前的为最新历史版本的测试软件***代码。
  19. 如权利要求16所述的计算机可读存储介质,其特征在于,所述比较所述被测软件***代码与所述最新历史版本代码,确定所述被测软件***代码是否被修改的步骤,具体包括:
    分析被测软件***代码与所述最新历史版本代码的结构关系;
    根据所述结构关系,判断被测软件***代码是否被修改,其中,所述结构关系为函数及方法的调用关系、结构的包含关系、类的继承关系。
  20. 如权利要求16-19任一项所述的计算机可读存储介质,其特征在于,所述将所述所有受影响的自动化测试脚本发送至所述终端设备的步骤,具体包括:
    将所有受影响的自动化测试脚本整理成图表或者报表,生成影响结果图;
    将所述影响结果图反馈至所述终端设备。
PCT/CN2018/089424 2017-12-15 2018-06-01 自动化测试分析方法、***、应用服务器及计算机可读存储介质 WO2019114209A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201711344740.7A CN107992424A (zh) 2017-12-15 2017-12-15 自动化测试分析方法、应用服务器及计算机可读存储介质
CN201711344740.7 2017-12-15

Publications (1)

Publication Number Publication Date
WO2019114209A1 true WO2019114209A1 (zh) 2019-06-20

Family

ID=62037888

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/089424 WO2019114209A1 (zh) 2017-12-15 2018-06-01 自动化测试分析方法、***、应用服务器及计算机可读存储介质

Country Status (2)

Country Link
CN (1) CN107992424A (zh)
WO (1) WO2019114209A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115203064A (zh) * 2022-09-19 2022-10-18 北京探境科技有限公司 代码检测方法、装置、计算机设备及可读存储介质

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107992424A (zh) * 2017-12-15 2018-05-04 平安科技(深圳)有限公司 自动化测试分析方法、应用服务器及计算机可读存储介质
CN109947657A (zh) * 2019-04-03 2019-06-28 广东电网有限责任公司 一种企业级信息管理***的变动范围分析方法和***
CN113360368B (zh) * 2020-03-06 2023-09-01 北京京东振世信息技术有限公司 一种软件性能测试的方法和装置
CN115858348B (zh) * 2022-11-24 2024-05-31 上海浦东发展银行股份有限公司 一种基于字节码的测试工作量评估方法、设备及介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100146340A1 (en) * 2008-12-09 2010-06-10 International Business Machines Corporation Analyzing Coverage of Code Changes
CN102831056A (zh) * 2012-07-31 2012-12-19 东南大学 一种基于修改影响分析的回归测试用例生成方法
CN103678097A (zh) * 2012-09-05 2014-03-26 百度在线网络技术(北京)有限公司 一种选择回归测试用例的方法和装置
CN103870384A (zh) * 2012-12-11 2014-06-18 航天信息股份有限公司 测试用例推定方法及***
CN104536896A (zh) * 2015-01-12 2015-04-22 牟永敏 面向函数调用路径的回归测试用例选择与排序方法及***
CN106547678A (zh) * 2015-09-16 2017-03-29 伊姆西公司 用于白盒测试的方法和装置
CN107992424A (zh) * 2017-12-15 2018-05-04 平安科技(深圳)有限公司 自动化测试分析方法、应用服务器及计算机可读存储介质

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100466556C (zh) * 2007-03-30 2009-03-04 华为技术有限公司 一种网络设备管理的方法和***
CN100576172C (zh) * 2008-05-27 2009-12-30 华耀环宇科技(北京)有限公司 一种通过分析代码变化确定功能点变化的方法
US8732663B2 (en) * 2010-02-24 2014-05-20 Salesforce.Com, Inc. System, method and computer program product for providing automated testing by utilizing a preconfigured point of entry in a test or by converting a test to a predefined format
CN106776339B (zh) * 2016-12-30 2018-07-24 深圳壹账通智能科技有限公司 自动化测试方法及装置

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100146340A1 (en) * 2008-12-09 2010-06-10 International Business Machines Corporation Analyzing Coverage of Code Changes
CN102831056A (zh) * 2012-07-31 2012-12-19 东南大学 一种基于修改影响分析的回归测试用例生成方法
CN103678097A (zh) * 2012-09-05 2014-03-26 百度在线网络技术(北京)有限公司 一种选择回归测试用例的方法和装置
CN103870384A (zh) * 2012-12-11 2014-06-18 航天信息股份有限公司 测试用例推定方法及***
CN104536896A (zh) * 2015-01-12 2015-04-22 牟永敏 面向函数调用路径的回归测试用例选择与排序方法及***
CN106547678A (zh) * 2015-09-16 2017-03-29 伊姆西公司 用于白盒测试的方法和装置
CN107992424A (zh) * 2017-12-15 2018-05-04 平安科技(深圳)有限公司 自动化测试分析方法、应用服务器及计算机可读存储介质

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115203064A (zh) * 2022-09-19 2022-10-18 北京探境科技有限公司 代码检测方法、装置、计算机设备及可读存储介质

Also Published As

Publication number Publication date
CN107992424A (zh) 2018-05-04

Similar Documents

Publication Publication Date Title
WO2019114209A1 (zh) 自动化测试分析方法、***、应用服务器及计算机可读存储介质
WO2019071891A1 (zh) 代码覆盖率分析方法及应用服务器
US8782609B2 (en) Test failure bucketing
US9569325B2 (en) Method and system for automated test and result comparison
US9104796B2 (en) Correlation of source code with system dump information
CN107329894B (zh) 应用程序***测试方法、装置及电子设备
US10133651B2 (en) Software defect analysis tool
CN108470000B (zh) 通讯终端软件自动测试方法、***及介质
US11625315B2 (en) Software regression recovery via automated detection of problem change lists
CN109783324B (zh) ***运行预警方法及装置
US10140201B2 (en) Software defect detection tool
US11573780B2 (en) Automated generation of status chains for software updates
CN108255735B (zh) 关联环境测试方法、电子装置及计算机可读存储介质
CN113032257B (zh) 自动化测试方法、装置、计算机***和可读存储介质
CN115454869A (zh) 界面自动化测试方法、装置、设备及存储介质
CN110688305B (zh) 测试环境同步方法、装置、介质、电子设备
WO2019100690A1 (zh) 电子装置、测试的方法、***及计算机可读存储介质
CN114090113B (zh) 数据源处理插件动态加载的方法、装置、设备及存储介质
CN111399862A (zh) Windows缺失驱动的批量安装方法、装置和计算机设备
CN111694684A (zh) 存储设备的异常构造方法、装置、电子设备及存储介质
CN113342560A (zh) 一种故障处理方法、***、电子设备及存储介质
CN112416648A (zh) 数据校验方法及装置
CN106874191B (zh) 智能数据库执行方法及***
CN114840429A (zh) 识别版本冲突的方法、装置、设备、介质和程序产品
CN113010417A (zh) 基于自动化测试的脚本执行方法及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18888871

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 21.09.2020)

122 Ep: pct application non-entry in european phase

Ref document number: 18888871

Country of ref document: EP

Kind code of ref document: A1