CN114996155A - UI automatic regression testing method, system, electronic equipment and storage medium - Google Patents

UI automatic regression testing method, system, electronic equipment and storage medium Download PDF

Info

Publication number
CN114996155A
CN114996155A CN202210722636.1A CN202210722636A CN114996155A CN 114996155 A CN114996155 A CN 114996155A CN 202210722636 A CN202210722636 A CN 202210722636A CN 114996155 A CN114996155 A CN 114996155A
Authority
CN
China
Prior art keywords
searching
elements
result
configuration file
information
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
CN202210722636.1A
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.)
Jiangsu Yincheng Network Technology Co Ltd
Original Assignee
Jiangsu Yincheng Network 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 Jiangsu Yincheng Network Technology Co Ltd filed Critical Jiangsu Yincheng Network Technology Co Ltd
Priority to CN202210722636.1A priority Critical patent/CN114996155A/en
Publication of CN114996155A publication Critical patent/CN114996155A/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/3684Test management for test design, e.g. generating new test cases
    • 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/3692Test management for test results analysis
    • 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/445Program loading or initiating
    • G06F9/44505Configuring for program initiating, e.g. using registry, configuration files

Landscapes

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

Abstract

The embodiment of the invention discloses a UI automatic regression testing method, a system, electronic equipment and a storage medium, which relate to the technical field of testing of web pages, and the method comprises the following steps: reading execution environment information and element information from the acquired configuration file; searching and obtaining corresponding elements in the execution environment according to the element information; issuing a called operation instruction to the element to obtain an operation result of the element; the method provided by the invention has the advantages that the element information is managed uniformly, the use case script is simpler, and the subsequent modification and maintenance are more convenient; a retry mechanism is added in element searching, so that case failure caused by environmental instability is avoided to the greatest extent, and the testing time is saved; element searching and operation are packaged uniformly, inlets are uniform, functions can be multiplexed, and the same functions do not need to be realized repeatedly; the frame reusability is high, the robustness is strong, and the manual regression cost can be greatly reduced.

Description

UI automatic regression testing method, system, electronic equipment and storage medium
Technical Field
The invention relates to the technical field of testing of web pages, in particular to a UI automatic regression testing method, a UI automatic regression testing system, electronic equipment and a storage medium.
Background
With the rapid development of company business, more and more foreground pages are responsible for departments. The current department adopts an agile development mode, the period of each iteration is very short, and therefore the test also needs to be agile.
The UI automatic test can simulate the user operation most truly, only the test of the server interface does not relate to the front-end layer, the optical slave interface can not judge whether the system and the main process have loopholes, but the UI automatic test can at least ensure whether the verified points are smooth. However, the current regression test only adopts manual regression, which increases a large amount of repeated labor cost, and has the following disadvantages:
(1) element attributes are not managed uniformly: when the existing UI automation script is realized, the element attributes are directly stored in different use case scripts, all related scripts need to be modified when the element attributes are changed, and omission is easy to generate;
(2) common methods do not encapsulate: when the existing UI automation script is realized, different scripts repeatedly realize the same service functions (such as login, order placement and the like);
(3) the practical applicability of part of scripts is poor: when the existing UI automation script is implemented, functions such as waiting element loading and the like use relatively direct hard waiting processing (for example, operation is started after 5s of fixed writing in a code), and in actual conditions, page loading time is different on different devices in different network environments, so that the processing of direct hard waiting in the code is not suitable.
Disclosure of Invention
The embodiment of the invention aims to provide a UI automatic regression testing method, a UI automatic regression testing system, electronic equipment and a storage medium, which are used for solving the problems that the existing element attributes are not managed in a unified mode, and the actual applicability of part of scripts which are not packaged and processed by a public method is poor.
To achieve the above object, the following further illustrates the embodiments of the present invention in four aspects:
in a first aspect, a UI automated regression testing method is provided, where the method includes the following steps:
reading execution environment information and element information from the acquired configuration file;
searching and obtaining corresponding elements in the execution environment according to the element information;
issuing a called operation instruction to the element to obtain an operation result of the element;
and verifying the operation result to obtain a verification result.
With reference to the first aspect, a method for reading execution environment information and element information from an acquired configuration file includes the following steps:
acquiring a configuration file, and reading execution environment information and element information configured in the configuration file;
the execution environment information includes a browser type to be executed, and the element information includes an attribute and a positioning mode of an element.
With reference to the first aspect, the configuration file includes a plurality of elements disposed on different pages and the same page, and the elements are centrally managed according to the attribution of the pages.
With reference to the first aspect, the method for performing centralized management on the elements according to the attribution of the page includes the following steps:
dividing the elements arranged on different pages in the configuration file by adopting different areas;
and concentrating the elements arranged on the same page in the same area in the configuration file.
With reference to the first aspect, a method for finding a corresponding element in an execution environment according to element information includes the following steps:
acquiring a browser to be executed, and using a data packet to simulate and call a web browser;
searching elements in real time in the process of loading the page by the browser according to the attributes or the positioning modes of the elements;
and repeatedly searching for a plurality of times after the page loading is finished, highlighting the elements in the browser if the searching is successful, and storing the screenshots of the elements which are failed to search if the searching is failed.
With reference to the first aspect, the method for issuing the called operation instruction to the element to obtain the operation result of the element includes the following steps:
selecting an operation instruction according to the attribute of the searched element;
issuing an operation instruction corresponding to the element;
the element executes operation according to the operation instruction and obtains an operation result fed back by the page;
and the operation instructions are integrated and packaged according to instruction functions to form an operation instruction group.
With reference to the first aspect, the method for verifying the operation result to obtain the verification result includes the following steps:
verifying according to the operation result fed back by the page and an expected result;
after the verification is finished, if the operation result is consistent with the expected result, marking the test result as success;
if the operation result is inconsistent with the expected result, the operation result is different from the expected result, the operation result is marked as failure, and the current browser screenshot is acquired at the same time.
In a second aspect, there is provided a UI automated regression testing system, the system comprising:
an information acquisition module: the system comprises a configuration file, a storage unit and a control unit, wherein the configuration file is used for storing the execution environment information and the element information;
a searching module: the system is used for searching and obtaining corresponding elements in the execution environment according to the element information;
an operation module: the operation instruction is used for issuing the called operation instruction to the element to obtain the operation result of the element;
a checking module: and the operation result is verified to obtain a verification result.
In a third aspect, an electronic device is provided, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor, and the processor implements the steps of the UI automated regression testing method according to any one of the first aspect when executing the computer program.
In a fourth aspect, there is provided a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the UI automated regression test as recited in any one of the first aspects:
the embodiment of the invention has the following advantages:
1. element information is managed uniformly, the use case script is simpler, and subsequent modification and maintenance are more convenient;
2. the element searching increases a retry mechanism, so that case failure caused by unstable environment is avoided to the greatest extent, and the test time is saved;
3. element searching and operation are packaged uniformly, inlets are uniform, functions can be multiplexed, and the same functions do not need to be realized repeatedly;
4. the functions of element highlighting, failure screenshot and the like are added, and the threshold of subsequent positioning and problem analysis is reduced;
5. the frame reusability is high, the robustness is strong, and the manual regression cost can be greatly reduced.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below. It should be apparent that the drawings in the following description are merely exemplary, and that other embodiments can be derived from the drawings provided by those of ordinary skill in the art without inventive effort.
The structures, ratios, sizes, and the like shown in the present specification are only used for matching with the contents disclosed in the specification, so as to be understood and read by those skilled in the art, and are not used to limit the conditions that the present invention can be implemented, so that the present invention has no technical significance, and any structural modifications, changes in the ratio relationship, or adjustments of the sizes, without affecting the effects and the achievable by the present invention, should still fall within the range that the technical contents disclosed in the present invention can cover.
Fig. 1 is a schematic flow chart of a method according to an embodiment of the present invention.
Fig. 2 is a block diagram of a system according to an embodiment of the present invention.
Fig. 3 is a schematic diagram illustrating management of configuration file elements according to an embodiment of the present invention.
Fig. 4 is a schematic diagram illustrating successful highlighting of element searching according to an embodiment of the present invention.
Fig. 5 is a schematic diagram illustrating the operation steps of the method according to the embodiment of the present invention.
Detailed Description
The present invention is described in terms of particular embodiments, other advantages and features of the invention will become apparent to those skilled in the art from the following disclosure, and it is to be understood that the described embodiments are merely exemplary of the invention and that it is not intended to limit the invention to the particular embodiments disclosed. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In the description of the present invention, it is to be understood that the terms "center", "longitudinal", "lateral", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", and the like, indicate orientations or positional relationships based on those shown in the drawings, and are used only for convenience in describing the present invention and for simplicity in description, and do not indicate or imply that the referenced devices or elements must have a particular orientation, be constructed and operated in a particular orientation, and thus, are not to be construed as limiting the present invention. Furthermore, the terms "first", "second", etc. are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first," "second," etc. may explicitly or implicitly include one or more of that feature. In the description of the present invention, "a plurality" means two or more unless otherwise specified.
In the description of the present invention, it should be noted that, unless otherwise explicitly specified or limited, the terms "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meaning of the above terms in the present invention can be understood by those of ordinary skill in the art through specific situations.
In the method provided by the invention, the basic flow of UI automation is as follows: and searching the elements of the web page needing to be operated by using the script language according to a certain method rule of the attribute of the elements, and issuing specific instructions (such as clicking a button, inputting a text, pulling down and selecting) to the elements. Integrating and assembling a plurality of element operations, and verifying the element operations with an expected result to finally achieve the test purpose;
a user interface (UI, also called user interface) is a medium for interaction and information exchange between a system and a user, and it realizes conversion between an internal form of information and a human-acceptable form. The user interface is designed between a user and hardware to interactively communicate with each other, aims to enable the user to conveniently and efficiently operate the hardware to achieve bidirectional interaction and complete work expected to be completed by means of the hardware, is widely defined and comprises a human-computer interaction user interface and a graphical user interface, and the user interface exists in the field of human and mechanical information communication.
Use case (English: use case), or use case and use case translation, is a description of how the system responds to external requests in software engineering or system engineering, and is a technology for acquiring requirements through the use scene of the user. Each use case provides one or more scenarios that illustrate how the system interacts with the end user or other system, i.e., who can do what with the system, to achieve a clear business goal.
Regression testing refers to re-testing after old code has been modified to confirm that the modification did not introduce new errors or cause errors in other code. The automatic regression testing can greatly reduce the cost of the system testing, maintenance upgrading and other stages. The regression test is used as a component of the software life cycle, and occupies a great workload proportion in the whole software test process, and multiple regression tests can be carried out at each stage of software development. In progressive and fast iterative development, the continuous release of new versions makes regression testing more frequent, whereas in extreme programming methods it is even more required to perform regression testing several times per day. Therefore, it is significant to improve the efficiency and effectiveness of regression testing by selecting the correct regression testing strategy;
the following four aspects further illustrate the embodiments of the present invention:
as shown in fig. 1 and 5, a UI automated regression testing method includes the following steps:
s1: reading execution environment information and element information from the acquired configuration file;
the specific implementation steps comprise:
acquiring a configuration file, and reading execution environment information and element information configured in the configuration file;
the execution environment information comprises a browser type to be executed, and the element information comprises the attribute and the positioning mode of an element;
the configuration file comprises a plurality of elements arranged on different pages and the same page, and the elements are managed in a centralized manner according to the attribution of the pages;
dividing the elements arranged on different pages in the configuration file by adopting different areas;
the elements arranged on the same page are concentrated in the same area in the configuration file;
the step is mainly to realize unified management of the same element information, and an entry is set for adding, deleting, modifying and checking, so that modification and adjustment of subsequent tests are facilitated.
S101: firstly, reading a configuration file to obtain the configuration of an execution environment:
in order to achieve the purpose that UI automation can be executed on a specified environment and a browser, environment execution information is uniformly placed in a configuration file, and the environment information in the configuration file and the type of the browser to be executed are read each time initialization is executed. The corresponding browser window is opened when executing. The following program is executed in a test environment and used for performing the operation by using a chrome browser;
[envTag]
env_tag=tccTestEnv
browser_type=chrome;
s102: and calling the simulation browser according to the environment information:
after the browser to be executed is obtained in S101, different web browsers can be simulated and invoked by using the python-layer packet, and meanwhile, for convenience of subsequent operations, the browser is maximized during processing in the script, and the data packet is the python-layer packet.
S103: reading element information in the configuration file:
in order to avoid the problem that when the element attribute is changed, all related scripts are modified to generate omission, the invention provides a scheme for uniformly managing the elements in a configuration file;
the elements in different pages are partitioned into different regions, that is, as shown in fig. 3, which is a schematic diagram of the management of configuration file elements provided by the embodiment of the present invention, in the diagram, "xxl" and "apollo" represent two different pages;
an element on the same page is placed under the same area, and the key/value mode is adopted to indicate how the element can be located, for example, the logUserNameInput mode indicates that the element can be located by the name ═ userName mode, and logConfirmBtn can be located by the xpath ═// [ @ id ═ lognForm "]/div [3]/div [2]/button mode.
S2: searching and obtaining corresponding elements in the execution environment according to the element information;
the specific implementation steps comprise:
acquiring a browser to be executed, and using a data packet to simulate and call a web browser;
searching elements in real time in the process of loading the page by the browser according to the attributes or the positioning modes of the elements;
and repeatedly searching for a plurality of times after the page is loaded, if the searching is successful, highlighting the elements in the browser, and if the searching is failed, performing screenshot storage on the elements which are failed to be searched.
The method mainly comprises the following steps of after acquiring execution environment information and element information, positioning and finding elements in a page and operating the elements:
s201: searching elements on the page according to the element information:
in S103, the attributes of the elements are obtained, and it can be seen that different element supports are obtained in different manners (name/class/id/xpath, etc.), but in order to solve the problems that the common method is not encapsulated and the actual applicability of part of the script is poor, the search elements need to be encapsulated uniformly, and a unique entry is provided for the test script to call, which is convenient for locating problems and analyzing reasons. The specific search implementation process comprises the following steps:
a. loading a page, and judging whether the element is loaded on the current page successfully in real time;
b. if the element is not loaded, automatically waiting for the element to be loaded, and immediately starting to search the element after the element is successfully loaded;
c. searching corresponding elements according to the element attributes in the S103;
s202: whether the cyclic lookup element is successful:
after the element is searched in S201, because the network, the device, etc. may not load the element completely or locate the element in the first time, if the direct return fails, the probability of successful script execution is very low, so in order to reduce the execution error caused by the environmental reason, a retry mechanism is added: if the element is found out unsuccessfully, the search is automatically retried for 3 times, if the element is not found out after 3 times, the screenshot of the page is stored, and the subsequent positioning is facilitated; successfully searching the elements, highlighting the peripheries of the elements, and waiting for the next operation;
as shown in fig. 4, which is a schematic diagram of successful highlight of element search provided in the embodiment of the present invention, a positioning hundred-degree query input box is taken as an example in the diagram, and the highlight bottom color of the positioned input box is a dark color:
s203: calling the unified operation module after the search is successful:
after the elements are searched successfully, in order to solve the problem of manpower waste caused by the fact that different testers realize the same service function, the elements are packaged uniformly, and therefore the method achieves operation of different types of elements, such as input of an input box, button clicking, drop-down list selection and the like. Through the shared component of the front-end page, the operation method of the element can be shared and used in different scripts, and can be maintained uniformly in the follow-up process.
S3: issuing a called operation instruction to the element to obtain an operation result of the element;
the specific implementation steps comprise:
selecting an operation instruction according to the searched attribute of the element;
issuing an operation instruction corresponding to the element;
the element executes operation according to the operation instruction and obtains an operation result fed back by the page;
and the operation instructions are integrated and packaged according to instruction functions to form an operation instruction group.
S301: and (3) checking an operation result:
after the elements are searched and operated in S202, checking is carried out according to the operation result returned by the page and the expected result in the test script, such as whether the list display data is correct or not;
s4: verifying the operation result to obtain a verification result;
the specific implementation steps comprise:
verifying according to the operation result fed back by the page and an expected result;
after the verification is finished, if the operation result is consistent with the expected result, marking the test result as success;
if the operation result is inconsistent with the expected result, indicating that the operation result is different from the expected result, marking the operation result as failure, and simultaneously acquiring the current browser screenshot;
s401: marking an execution result and acquiring a failure screenshot:
after the verification is completed, if the verification result is consistent with the expected result, the execution of the test is successfully completed, and the success can be marked;
if the verification result is inconsistent with the expected result, the verification result is different from the expected result, and at the moment, the failure should be marked, and meanwhile, the current browser screenshot needs to be obtained for subsequent testers to analyze the result.
S402: and generating an Allure visualization result report:
after the test result marking of all the elements is finished, calling Allure to automatically generate a visual test report, wherein the execution result of the test is shown in the report;
the Allure framework is a flexible, lightweight, multi-lingual test reporting tool that not only presents profiled test results in a web-based manner, but also allows everyone participating in the development process to extract useful information to a maximum extent from the daily tests performed.
As shown in FIG. 2, a UI automated regression testing system is provided for a method according to the invention, the system comprising:
an information acquisition module: the system comprises a configuration file, a storage unit and a control unit, wherein the configuration file is used for storing the execution environment information and the element information;
a searching module: the system is used for searching and obtaining corresponding elements in the execution environment according to the element information;
an operation module: the operation instruction is used for issuing the called operation instruction to the element to obtain the operation result of the element;
a checking module: the operation result is verified to obtain a verification result;
the information acquisition module: the system comprises a configuration file and a server, wherein the configuration file is used for acquiring the configuration file and reading the execution environment information and the element information configured in the configuration file;
the execution environment information comprises a browser type to be executed, and the element information comprises the attribute and the positioning mode of an element;
the configuration file comprises a plurality of elements arranged on different pages and the same page, and the elements are managed in a centralized manner according to the attribution of the pages;
dividing the elements arranged on different pages in the configuration file by adopting different areas;
the elements arranged on the same page are concentrated in the same area in the configuration file;
the step is mainly to realize the unified management of the same element information and set an entrance for adding, deleting, modifying and checking, so as to facilitate the modification and adjustment of the subsequent test;
the search module: the system comprises a data packet generation module, a data packet generation module and a data packet transmission module, wherein the data packet generation module is used for generating a data packet;
searching elements in real time in the process of loading the page by the browser according to the attributes or the positioning modes of the elements;
and repeatedly searching for a plurality of times after the page loading is finished, highlighting the elements in the browser if the searching is successful, and storing the screenshots of the elements which are failed to search if the searching is failed.
The method mainly comprises the following steps of after acquiring execution environment information and element information, positioning and finding elements in a page and operating the elements:
the operation module is used for: the system comprises a searching unit, a storage unit and a display unit, wherein the searching unit is used for searching elements in the storage unit;
issuing an operation instruction corresponding to the element;
the element executes operation according to the operation instruction and obtains an operation result fed back by the page;
the operation instructions are integrated and packaged according to instruction functions to form an operation instruction group;
the checking module: the verification module is used for verifying the operation result fed back according to the page and an expected result;
after the verification is finished, if the operation result is consistent with the expected result, marking the test result as success;
if the operation result is inconsistent with the expected result, the operation result is different from the expected result, the operation result is marked as failure, and the current browser screenshot is acquired at the same time.
The method according to the present invention provides an electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the UI automated regression testing method as described above.
A non-transitory computer-readable storage medium, on which a computer program is stored, according to the method of the invention, characterized in that the computer program, when executed by a processor, implements the steps of the UI automated regression test as described above.
Although the invention has been described in detail above with reference to a general description and specific examples, it will be apparent to one skilled in the art that modifications or improvements may be made thereto based on the invention. Accordingly, it is intended that all such modifications and alterations be included within the scope of this invention as defined in the appended claims.

Claims (10)

1. A UI automated regression testing method, characterized in that the method comprises the following steps:
reading execution environment information and element information from the acquired configuration file;
searching and obtaining corresponding elements in the execution environment according to the element information;
issuing a called operation instruction to the element to obtain an operation result of the element;
and verifying the operation result to obtain a verification result.
2. The automated regression testing method for UIs of claim 1, wherein: the method for reading the execution environment information and the element information from the acquired configuration file comprises the following steps:
acquiring a configuration file, and reading execution environment information and element information configured in the configuration file;
the execution environment information includes a browser type to be executed, and the element information includes an attribute and a positioning mode of an element.
3. The automated regression testing method for UIs of claim 2, wherein: the configuration file comprises a plurality of elements arranged on different pages and the same page, and the elements are managed in a centralized manner according to the attribution of the pages.
4. The automated regression testing method for UIs according to claim 3, wherein: the method for carrying out centralized management on the elements according to the attribution of the page comprises the following steps:
dividing the elements arranged on different pages in the configuration file by adopting different areas;
and concentrating the elements arranged on the same page in the same area in the configuration file.
5. The automated regression testing method for UIs according to claim 4, wherein: the method for searching and obtaining the corresponding element in the execution environment according to the element information comprises the following steps:
acquiring a browser to be executed, and using a data packet to simulate and call a web browser;
searching elements in real time in the process of loading the page by the browser according to the attributes or the positioning modes of the elements;
and repeatedly searching for a plurality of times after the page loading is finished, highlighting the elements in the browser if the searching is successful, and storing the screenshots of the elements which are failed to search if the searching is failed.
6. The UI automated regression testing method of claim 5, wherein: the method for issuing the called operation instruction to the element and obtaining the operation result of the element comprises the following steps:
selecting an operation instruction according to the searched attribute of the element;
issuing an operation instruction corresponding to the element;
the element executes operation according to the operation instruction and obtains an operation result fed back by the page;
and the operation instructions are integrated and packaged according to instruction functions to form an operation instruction group.
7. The automated regression testing method for UIs according to claim 6, wherein: the method for verifying the operation result to obtain the verification result comprises the following steps:
verifying according to the operation result fed back by the page and an expected result;
after the verification is finished, if the operation result is consistent with the expected result, marking the test result as success;
if the operation result is inconsistent with the expected result, the operation result is different from the expected result, the operation result is marked as failure, and the current browser screenshot is acquired at the same time.
8. A UI automated regression testing system, comprising: the system comprises:
an information acquisition module: the system comprises a configuration file, a storage unit and a control unit, wherein the configuration file is used for storing the execution environment information and the element information;
a searching module: the system is used for searching and obtaining corresponding elements in the execution environment according to the element information;
an operation module: the operation instruction is used for issuing the called operation instruction to the element to obtain the operation result of the element;
a checking module: and the operation result is verified to obtain a verification result.
9. An electronic device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor when executing the computer program implements the steps of the UI automated regression testing method of any one of claims 1 to 7.
10. A non-transitory computer readable storage medium having stored thereon a computer program, wherein the computer program, when executed by a processor, implements the steps of the UI automated regression test of any of claims 1 to 7.
CN202210722636.1A 2022-06-20 2022-06-20 UI automatic regression testing method, system, electronic equipment and storage medium Pending CN114996155A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210722636.1A CN114996155A (en) 2022-06-20 2022-06-20 UI automatic regression testing method, system, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210722636.1A CN114996155A (en) 2022-06-20 2022-06-20 UI automatic regression testing method, system, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114996155A true CN114996155A (en) 2022-09-02

Family

ID=83036781

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210722636.1A Pending CN114996155A (en) 2022-06-20 2022-06-20 UI automatic regression testing method, system, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114996155A (en)

Similar Documents

Publication Publication Date Title
US11379348B2 (en) System and method for performing automated API tests
US11281570B2 (en) Software testing method, system, apparatus, device medium, and computer program product
US10108535B2 (en) Web application test script generation to test software functionality
CN106844217B (en) Method and device for embedding point of applied control and readable storage medium
US7810070B2 (en) System and method for software testing
Memon Automatically repairing event sequence-based GUI test suites for regression testing
CN108446190B (en) Interface test method and device
US8914679B2 (en) Software testing automation framework
US8151248B1 (en) Method and system for software defect management
US7877732B2 (en) Efficient stress testing of a service oriented architecture based application
CN111209185B (en) Keyword-based automated testing method and computer-readable storage medium
US20130275946A1 (en) Systems and methods for test development process automation for a test harness
CN109902017A (en) A kind of method and terminal based on RobotFramework test Dubbo interface
CN113760763A (en) Software testing method, device, server and system
CN112181854A (en) Method, device, equipment and storage medium for generating flow automation script
CN111966587A (en) Data acquisition method, device and equipment
CN111966575B (en) Graphic automatic test method for aviation onboard display software
CN114996155A (en) UI automatic regression testing method, system, electronic equipment and storage medium
CN115599683A (en) Automatic testing method, device, equipment and storage medium
CN114490892A (en) Data transmission method and device based on datax
CN113485919A (en) Test method, test device and computer readable storage medium
CN113220586A (en) Automatic interface pressure test execution method, device and system
CN111221610A (en) Page element acquisition method and device
CN111400190A (en) Automatic test flow generation method and device and computer readable storage medium
US20170068523A1 (en) Modular Computer Application Development and Usage

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