Background
The browser is used as an important carrier of information transfer, the web page bears a platform of various website applications, and in order to complete function tests on the PC end and the mobile end, manual operation is usually required on the equipment. In the prior art, a series of processes of browsing a webpage by a user and outputting a test report can be simulated by inputting and executing codes by using a browser development tool console, so that an automatic test effect of simulating manual operation is achieved. The method comprises the steps of designing, compiling and packaging codes, introducing a script code library, defining users, events, network requests, timing tasks, data caching, data transmission and the like, defining various schemes, inputting a small number of configuration items and adapting to more user scenes or functional modules. For example, after a user page is simulated to enter a page, after webpage resources are loaded, the page is controlled to operate an input box, operate a button, execute click time and browser rolling events after a few seconds, manual operation is replaced, meanwhile, the dwell time is automatically counted, and the page resource request condition is captured.
In the prior art, a browser is opened manually, a webpage address is input, a browser developer tool is opened, a test code is written manually, and the whole process depends on more manual operations; the requirement on personnel capacity is high, the debugging code needs to use the bottom-layer programming capacity, and a complete resource library such as a frame or an assembly which does not improve the coding efficiency is convenient to introduce; no test case integration, test suite; and lacks the ability to automatically output test reports.
Disclosure of Invention
The invention aims to overcome the defects of the prior art, and provides a Web automatic testing method and system based on a browser, a storage medium and terminal equipment, so that automatic testing is realized, and manual operation in the testing process is reduced.
In order to solve at least one technical problem, an embodiment of the present invention provides a Web automation testing method based on a browser, where the method includes:
when a user interface based on a browser enters a console of a developer mode, the browser downloads Web resources on a server side based on an HTTP request;
presenting the Web resource in a window of the browser to obtain a presented webpage interface;
receiving a test instruction generated by an operator in the console;
and calling a corresponding resource parameter function in an automatic testing system in the console based on the testing instruction to automatically execute the simulation user operation test processing on the webpage interface to obtain a test result.
Optionally, the browser includes a presentation engine, a network component, a UI backend, a js parser, and a data store; the presentation engine is responsible for analyzing and displaying the Web resource content requested to be presented; the network component is responsible for generating HTTP network requests; the UI back end is responsible for drawing a webpage interface; the js parser is responsible for parsing and executing js codes; and the data storage is responsible for storing the data required by the browser on a hard disk.
Optionally, the presenting the Web resource in the window of the browser to obtain a presented Web interface includes:
analyzing the HTML document in the Web resource, and constructing a DOM tree based on the analysis result;
rendering the DOM tree, and analyzing the style attributes of external CSS files and elements in the rendering process to obtain a rendering tree;
positioning each node in the rendering tree on an exact coordinate of a screen, and drawing on the exact coordinate;
and traversing each node in the drawing process and drawing by using the UI rear end to form a presented webpage interface.
Optionally, the rendering tree includes a plurality of visual effects and rectangles in a display order in contention;
the rendered web page interface includes regions other than a web page content form, including an address bar, a status bar, a toolbar, and a back leg/forward button.
Optionally, the console allows standard JavaScript statements and special commands to be used to help debug the web interface.
Optionally, the resource parameter function includes a resource library, a framework, an interaction flow, a test case, and a test report;
the resource library is used for providing common functions, test tools, common plug-ins and data structure operations; the framework is used for providing an API; the interaction flow is used for providing interaction rules, jump paths and conventional event flow instructions of the pages; the test tool provides a set of test inputs, execution conditions, and expected results tailored to a particular objective for verifying that a particular requirement is met; the test report is used for delivering all documents included in the test process, including a test plan, a test case/case, a defect record and a test report.
Optionally, the invoking, in the console, a corresponding resource parameter function in an automated testing system based on the test instruction to perform automatic execution of a simulation user operation test process on the web interface to obtain a test result includes:
the control console establishes a test connection with the automatic test system;
and after the control console receives the test instruction, sequentially calling a resource library, a frame, an interactive flow, a test case and a test report in the automatic test system based on the control console to automatically execute the test processing of simulating the user operation on the webpage interface to obtain a test result.
In addition, an embodiment of the present invention further provides a Web automation testing apparatus based on a browser, where the apparatus includes:
a downloading module: the method comprises the steps that when a user interface based on a browser enters a console of a developer mode, the browser downloads Web resources on a server side based on an HTTP request;
a presentation module: the Web resource is presented in the window of the browser, and a presented webpage interface is obtained;
a generation module: the test system is used for receiving a test instruction generated by an operator in the operation of the console;
an automatic test module: and the system is used for calling a corresponding resource parameter function in an automatic testing system in the control console based on the testing instruction to automatically execute the simulation user operation testing processing on the webpage interface to obtain a testing result.
In addition, an embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored, where the computer program, when executed by a processor, implements any one of the above described Web automation testing methods.
In addition, an embodiment of the present invention further provides a terminal device, which includes:
one or more processors;
a memory;
one or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the one or more processors, the one or more applications configured to: and executing the Web automatic testing method.
In the embodiment of the invention, the automatic test system provides abundant automatic test methods, so that more manual operations are reduced in the whole process; a standard frame and operation steps are provided, so that technical storage or filing is facilitated; providing a js command of a simple control console, unifying and standardizing, and reducing professional thresholds, wherein the js command can be used by non-professional technicians except developers, testers, product managers and the like; providing test case integration and a test suite; and provide the template of the automatic output test report, realize the automatic generation and output test report, in order to reach the test goal; the invention provides a packaged complete test flow, and a user can complete the scenes of page debugging, page interaction, event binding and execution, interface joint debugging and the like only by inputting a small amount of command line codes according to a configuration description document without knowing an internal implementation principle. The learning cost is reduced, and the testing efficiency is improved.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. 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.
Examples
Referring to fig. 1, fig. 1 is a flowchart illustrating a Web automation testing method based on a browser in an embodiment of the present invention.
As shown in fig. 1, a method for Web automation test based on browser includes:
s11: when a user interface based on a browser enters a console of a developer mode, the browser downloads Web resources on a server side based on an HTTP request;
in the specific implementation process of the invention, the browser comprises a presentation engine, a network component, a UI rear end, a js parser and a data storage; the presentation engine is responsible for analyzing and displaying the Web resource content requested to be presented; the network component is responsible for generating HTTP network requests; the UI back end is responsible for drawing a webpage interface; the js parser is responsible for parsing and executing js codes; and the data storage is responsible for storing the data required by the browser on a hard disk.
Specifically, when a user enters a console of a developer mode through a browser, the browser sends an HTTP request to a server through a built-in network component of the browser, and the request content is a downloaded Web resource; after receiving the request, the server establishes connection with the browser and issues the Web resource to the browser, so that the browser downloads the Web resource on the server side.
The browser comprises a presentation engine, a network component, a UI rear end, a js parser and a data storage; the UI (interface) comprises an address bar, a status bar, a tool bar and a back/forward button except for a webpage content form; transmitting instructions between the browser engine user interface and the presentation engine; the presentation (rendering) engine is responsible for parsing and displaying the requested content; the network component is responsible for network requests, such as HTTP requests; the UI back end is responsible for drawing basic widgets, such as system modal popup; the js parser is responsible for parsing and executing js codes; data storage: the browser needs various data stored on the hard disk.
S12: presenting the Web resource in a window of the browser to obtain a presented webpage interface;
in a specific implementation process of the present invention, the presenting the Web resource in the window of the browser to obtain a presented Web interface includes: analyzing the HTML document in the Web resource, and constructing a DOM tree based on the analysis result; rendering the DOM tree, and analyzing the style attributes of external CSS files and elements in the rendering process to obtain a rendering tree; positioning each node in the rendering tree on an exact coordinate of a screen, and drawing on the exact coordinate; and traversing each node in the drawing process and drawing by using the UI rear end to form a presented webpage interface.
Further, the rendering tree includes a plurality of visual effects and rectangles in a display order in contention; the rendered web page interface includes regions other than a web page content form, including an address bar, a status bar, a toolbar, and a back leg/forward button.
Specifically, an HTML document in a downloaded Web resource is analyzed in the browser, an analysis result is obtained, and then a DOM tree is constructed according to the analysis result; rendering the DOM tree, and analyzing the style attributes of external CSS files and elements in the rendering process to obtain a rendering tree; locating each node in the render tree at an exact coordinate, typically a pixel coordinate, on the screen of the terminal; drawing on the exact coordinates; and traversing each node in the drawing process and drawing by using the UI rear end to form a webpage interface of the program.
Analyzing an HTML document to construct a DOM tree, analyzing style attributes of external CSS files and elements in a rendering process, wherein the rendering tree comprises a plurality of visual effects and is a rectangle in a correct display sequence, positioning each node on an exact coordinate of a screen in a layout process, and traversing each node in a drawing process to draw by using a UI rear end; the rendered web page interface also includes areas other than the web page content form, including an address bar, a status bar, a toolbar, and back/forward buttons.
S13: receiving a test instruction generated by an operator in the console;
in the specific implementation process of the invention, the console allows the standard JavaScript statements and special commands to be used to help debug the webpage interface.
Specifically, after a user (operator) enters a console in a developer mode through a user interface of a browser, a test instruction generating operation is performed on the console, that is, the console receives a corresponding operation performed by the operator on the console, and generates a test instruction.
The console allows standard JavaScript statements and special commands to be used to help debug the webpage interface; the console can view diagnostic information, display rich structured data, control and filter output, detect and modify page elements, measure execution time, and the like; including diagnostics and logging to the console, comparing similar data objects, measurement and statistics execution, exception and error handling, and console API referencing.
The post role of receiving the operator can be a developer, a tester and a product manager, and the automatic testing step based on the browser can be completed only by being familiar with the technology.
S14: and calling a corresponding resource parameter function in an automatic testing system in the console based on the testing instruction to automatically execute the simulation user operation test processing on the webpage interface to obtain a test result.
In the specific implementation process of the invention, the resource parameter function comprises a resource library, a frame, an interactive flow, a test case and a test report; the resource library is used for providing common functions, test tools, common plug-ins and data structure operations; the framework is used for providing an API; the interaction flow is used for providing interaction rules, jump paths and conventional event flow instructions of the pages; the test tool provides a set of test inputs, execution conditions, and expected results tailored to a particular objective for verifying that a particular requirement is met; the test report is used for delivering all documents included in the test process, including a test plan, a test case/case, a defect record and a test report.
Further, the invoking, in the console, a corresponding resource parameter function in an automated testing system based on the test instruction to perform automatic execution of a simulation user operation test process on the web interface to obtain a test result includes: the control console establishes a test connection with the automatic test system; and after the control console receives the test instruction, sequentially calling a resource library, a frame, an interactive flow, a test case and a test report in the automatic test system based on the control console to automatically execute the test processing of simulating the user operation on the webpage interface to obtain a test result.
Specifically, after the console generates the test instruction, the corresponding resource parameter function in the automated testing system is called in the console according to the test instruction to automatically execute the simulation user operation test on the web interface, so as to obtain the test result.
Before testing, firstly, the console is required to establish test connection with the automatic test system; and then after the control console receives the test instruction, the resource library, the frame, the interactive flow, the test case and the test report in the automatic test system are sequentially called by the control console to automatically execute the simulation user operation test processing on the webpage interface, and a test result is obtained.
The automatic test system integrates a plurality of resource parameter function modules such as a resource library, a frame, an interactive flow, a test case, a test report and the like, and aims to input a test instruction conveniently through a control console of a browser, then call the automatic parameter system to complete automatic operation and complete a series of automatic tests.
The resource parameter function of the automatic test system comprises a resource library, a framework, an interactive process, a test case, a test report and an extension module. The resource library is used for providing a commonly used resource library, solving commonly used functions, tool methods, data structure operations, commonly used plug-ins and the like. The framework is used for providing simple and convenient API, selectively adding modules, unifying the specification, being easy to integrate with other libraries and projects, being simple and easy to use and being convenient for a user to operate; such as providing selectors, DOM traversal and operations, utility functions, tool methods, event processing, AJAX requests. The interaction flow is used for providing instructions such as interaction rules, jump paths, conventional event flows and the like of the pages; for example, the a page jumps to the B page, and the operation of clicking the button is performed. The test case is used for a set of test inputs, execution conditions, and expected results compiled for a particular target, and is used to verify whether a particular requirement is met, including test targets, test environments, input data, test steps, expected results, test scripts, and the like. The test includes the steps of delivering all included documents in the test process, mainly including test plans, test cases/cases, defect records and test reports. Defining a test report template, and after executing a test case, automatically generating a related test report, such as a functional test, and ensuring that the function of a test object is normal, wherein the related test report comprises functions of a business process, data processing, a boundary value and the like, all test requirements and cases are covered, the test is finished in an ST environment, the number of effective cases is xx, the execution rate is xx%, the success rate is xx%, the defect closing rate is xx%, and the defects are repaired and returned to be closed at present. The expansion module is used for reserving addition of more modules, so that the expansibility is well made, the subsequent test is more automatic, and the test precision is higher.
In the embodiment of the invention, the automatic test system provides abundant automatic test methods, so that more manual operations are reduced in the whole process; a standard frame and operation steps are provided, so that technical storage or filing is facilitated; providing a js command of a simple control console, unifying and standardizing, and reducing professional thresholds, wherein the js command can be used by non-professional technicians except developers, testers, product managers and the like; providing test case integration and a test suite; and provide the template of the automatic output test report, realize the automatic generation and output test report, in order to reach the test goal; the invention provides a packaged complete test flow, and a user can complete the scenes of page debugging, page interaction, event binding and execution, interface joint debugging and the like only by inputting a small amount of command line codes according to a configuration description document without knowing an internal implementation principle. The learning cost is reduced, and the testing efficiency is improved.
Examples
Referring to fig. 2, fig. 2 is a schematic structural component diagram of a Web automation testing apparatus based on a browser in an embodiment of the present invention.
As shown in fig. 2, a Web automation test device based on a browser, the device includes:
the downloading module 21: the method comprises the steps that when a user interface based on a browser enters a console of a developer mode, the browser downloads Web resources on a server side based on an HTTP request;
in the specific implementation process of the invention, the browser comprises a presentation engine, a network component, a UI rear end, a js parser and a data storage; the presentation engine is responsible for analyzing and displaying the Web resource content requested to be presented; the network component is responsible for generating HTTP network requests; the UI back end is responsible for drawing a webpage interface; the js parser is responsible for parsing and executing js codes; and the data storage is responsible for storing the data required by the browser on a hard disk.
Specifically, when a user enters a console of a developer mode through a browser, the browser sends an HTTP request to a server through a built-in network component of the browser, and the request content is a downloaded Web resource; after receiving the request, the server establishes connection with the browser and issues the Web resource to the browser, so that the browser downloads the Web resource on the server side.
The browser comprises a presentation engine, a network component, a UI rear end, a js parser and a data storage; the UI (interface) comprises an address bar, a status bar, a tool bar and a back/forward button except for a webpage content form; transmitting instructions between the browser engine user interface and the presentation engine; the presentation (rendering) engine is responsible for parsing and displaying the requested content; the network component is responsible for network requests, such as HTTP requests; the UI back end is responsible for drawing basic widgets, such as system modal popup; the js parser is responsible for parsing and executing js codes; data storage: the browser needs various data stored on the hard disk.
The presentation module 22: the Web resource is presented in the window of the browser, and a presented webpage interface is obtained;
in a specific implementation process of the present invention, the presenting the Web resource in the window of the browser to obtain a presented Web interface includes: analyzing the HTML document in the Web resource, and constructing a DOM tree based on the analysis result; rendering the DOM tree, and analyzing the style attributes of external CSS files and elements in the rendering process to obtain a rendering tree; positioning each node in the rendering tree on an exact coordinate of a screen, and drawing on the exact coordinate; and traversing each node in the drawing process and drawing by using the UI rear end to form a presented webpage interface.
Further, the rendering tree includes a plurality of visual effects and rectangles in a display order in contention; the rendered web page interface includes regions other than a web page content form, including an address bar, a status bar, a toolbar, and a back leg/forward button.
Specifically, an HTML document in a downloaded Web resource is analyzed in the browser, an analysis result is obtained, and then a DOM tree is constructed according to the analysis result; rendering the DOM tree, and analyzing the style attributes of external CSS files and elements in the rendering process to obtain a rendering tree; locating each node in the render tree at an exact coordinate, typically a pixel coordinate, on the screen of the terminal; drawing on the exact coordinates; and traversing each node in the drawing process and drawing by using the UI rear end to form a webpage interface of the program.
Analyzing an HTML document to construct a DOM tree, analyzing style attributes of external CSS files and elements in a rendering process, wherein the rendering tree comprises a plurality of visual effects and is a rectangle in a correct display sequence, positioning each node on an exact coordinate of a screen in a layout process, and traversing each node in a drawing process to draw by using a UI rear end; the rendered web page interface also includes areas other than the web page content form, including an address bar, a status bar, a toolbar, and back/forward buttons.
The generation module 23: the test system is used for receiving a test instruction generated by an operator in the operation of the console;
in the specific implementation process of the invention, the console allows the standard JavaScript statements and special commands to be used to help debug the webpage interface.
Specifically, after a user (operator) enters a console in a developer mode through a user interface of a browser, a test instruction generating operation is performed on the console, that is, the console receives a corresponding operation performed by the operator on the console, and generates a test instruction.
The console allows standard JavaScript statements and special commands to be used to help debug the webpage interface; the console can view diagnostic information, display rich structured data, control and filter output, detect and modify page elements, measure execution time, and the like; including diagnostics and logging to the console, comparing similar data objects, measurement and statistics execution, exception and error handling, and console API referencing.
The post role of receiving the operator can be a developer, a tester and a product manager, and the automatic testing step based on the browser can be completed only by being familiar with the technology.
The automatic test module 24: and the system is used for calling a corresponding resource parameter function in an automatic testing system in the control console based on the testing instruction to automatically execute the simulation user operation testing processing on the webpage interface to obtain a testing result.
In the specific implementation process of the invention, the resource parameter function comprises a resource library, a frame, an interactive flow, a test case and a test report; the resource library is used for providing common functions, test tools, common plug-ins and data structure operations; the framework is used for providing an API; the interaction flow is used for providing interaction rules, jump paths and conventional event flow instructions of the pages; the test tool provides a set of test inputs, execution conditions, and expected results tailored to a particular objective for verifying that a particular requirement is met; the test report is used for delivering all documents included in the test process, including a test plan, a test case/case, a defect record and a test report.
Further, the invoking, in the console, a corresponding resource parameter function in an automated testing system based on the test instruction to perform automatic execution of a simulation user operation test process on the web interface to obtain a test result includes: the control console establishes a test connection with the automatic test system; and after the control console receives the test instruction, sequentially calling a resource library, a frame, an interactive flow, a test case and a test report in the automatic test system based on the control console to automatically execute the test processing of simulating the user operation on the webpage interface to obtain a test result.
Specifically, after the console generates the test instruction, the corresponding resource parameter function in the automated testing system is called in the console according to the test instruction to automatically execute the simulation user operation test on the web interface, so as to obtain the test result.
Before testing, firstly, the console is required to establish test connection with the automatic test system; and then after the control console receives the test instruction, the resource library, the frame, the interactive flow, the test case and the test report in the automatic test system are sequentially called by the control console to automatically execute the simulation user operation test processing on the webpage interface, and a test result is obtained.
The automatic test system integrates a plurality of resource parameter function modules such as a resource library, a frame, an interactive flow, a test case, a test report and the like, and aims to input a test instruction conveniently through a control console of a browser, then call the automatic parameter system to complete automatic operation and complete a series of automatic tests.
The resource parameter function of the automatic test system comprises a resource library, a framework, an interactive process, a test case, a test report and an extension module. The resource library is used for providing a commonly used resource library, solving commonly used functions, tool methods, data structure operations, commonly used plug-ins and the like. The framework is used for providing simple and convenient API, selectively adding modules, unifying the specification, being easy to integrate with other libraries and projects, being simple and easy to use and being convenient for a user to operate; such as providing selectors, DOM traversal and operations, utility functions, tool methods, event processing, AJAX requests. The interaction flow is used for providing instructions such as interaction rules, jump paths, conventional event flows and the like of the pages; for example, the a page jumps to the B page, and the operation of clicking the button is performed. The test case is used for a set of test inputs, execution conditions, and expected results compiled for a particular target, and is used to verify whether a particular requirement is met, including test targets, test environments, input data, test steps, expected results, test scripts, and the like. The test includes the steps of delivering all included documents in the test process, mainly including test plans, test cases/cases, defect records and test reports. Defining a test report template, and after executing a test case, automatically generating a related test report, such as a functional test, and ensuring that the function of a test object is normal, wherein the related test report comprises functions of a business process, data processing, a boundary value and the like, all test requirements and cases are covered, the test is finished in an ST environment, the number of effective cases is xx, the execution rate is xx%, the success rate is xx%, the defect closing rate is xx%, and the defects are repaired and returned to be closed at present. The expansion module is used for reserving addition of more modules, so that the expansibility is well made, the subsequent test is more automatic, and the test precision is higher.
In the embodiment of the invention, the automatic test system provides abundant automatic test methods, so that more manual operations are reduced in the whole process; a standard frame and operation steps are provided, so that technical storage or filing is facilitated; providing a js command of a simple control console, unifying and standardizing, and reducing professional thresholds, wherein the js command can be used by non-professional technicians except developers, testers, product managers and the like; providing test case integration and a test suite; and provide the template of the automatic output test report, realize the automatic generation and output test report, in order to reach the test goal; the invention provides a packaged complete test flow, and a user can complete the scenes of page debugging, page interaction, event binding and execution, interface joint debugging and the like only by inputting a small amount of command line codes according to a configuration description document without knowing an internal implementation principle. The learning cost is reduced, and the testing efficiency is improved.
The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the computer program implements the Web automation testing method according to any one of the embodiments. The computer-readable storage medium includes, but is not limited to, any type of disk including floppy disks, hard disks, optical disks, CD-ROMs, and magneto-optical disks, ROMs (Read-Only memories), RAMs (Random AcceSS memories), EPROMs (EraSable Programmable Read-Only memories), EEPROMs (Electrically EraSable Programmable Read-Only memories), flash memories, magnetic cards, or optical cards. That is, a storage device includes any medium that stores or transmits information in a form readable by a device (e.g., a computer, a cellular phone), and may be a read-only memory, a magnetic or optical disk, or the like.
The embodiment of the invention also provides a computer application program which runs on a computer and is used for executing the Web automatic testing method of any one of the embodiments.
In addition, fig. 3 is a schematic structural composition diagram of the terminal device in the embodiment of the present invention.
An embodiment of the present invention further provides a terminal device, as shown in fig. 3. The terminal device includes a processor 302, a memory 303, an input unit 304, a display unit 305, and the like. Those skilled in the art will appreciate that the device configuration means shown in fig. 3 do not constitute a limitation of all devices and may include more or less components than those shown, or some components in combination. The memory 303 may be used to store the application 301 and various functional modules, and the processor 302 executes the application 301 stored in the memory 303, thereby performing various functional applications of the device and data processing. The memory may be internal or external memory, or include both internal and external memory. The memory may comprise read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), flash memory, or random access memory. The external memory may include a hard disk, a floppy disk, a ZIP disk, a usb-disk, a magnetic tape, etc. The disclosed memory includes, but is not limited to, these types of memory. The disclosed memory is by way of example only and not by way of limitation.
The input unit 304 is used for receiving input of signals and receiving keywords input by a user. The input unit 304 may include a touch panel and other input devices. The touch panel can collect touch operations of a user on or near the touch panel (for example, operations of the user on or near the touch panel by using any suitable object or accessory such as a finger, a stylus and the like) and drive the corresponding connecting device according to a preset program; other input devices may include, but are not limited to, one or more of a physical keyboard, function keys (e.g., play control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like. The display unit 305 may be used to display information input by a user or information provided to the user and various menus of the server. The display unit 305 may take the form of a liquid crystal display, an organic light emitting diode, or the like. The processor 302 is a control center of the server, connects various parts of the entire apparatus using various interfaces and lines, performs various functions and processes data by operating or executing software programs and/or modules stored in the memory 302, and calling data stored in the memory.
As an embodiment, the terminal device includes: one or more processors 302, a memory 303, one or more applications 301, wherein the one or more applications 301 are stored in the memory 303 and configured to be executed by the one or more processors 302, and wherein the one or more applications 301 are configured to perform the method for Web automation testing of any of the above embodiments.
In the embodiment of the invention, the automatic test system provides abundant automatic test methods, so that more manual operations are reduced in the whole process; a standard frame and operation steps are provided, so that technical storage or filing is facilitated; providing a js command of a simple control console, unifying and standardizing, and reducing professional thresholds, wherein the js command can be used by non-professional technicians except developers, testers, product managers and the like; providing test case integration and a test suite; and provide the template of the automatic output test report, realize the automatic generation and output test report, in order to reach the test goal; the invention provides a packaged complete test flow, and a user can complete the scenes of page debugging, page interaction, event binding and execution, interface joint debugging and the like only by inputting a small amount of command line codes according to a configuration description document without knowing an internal implementation principle. The learning cost is reduced, and the testing efficiency is improved.
In addition, the above detailed description is given to a method, a system, a storage medium, and a terminal device for Web automation test based on a browser according to an embodiment of the present invention, and a specific example should be used herein to explain the principle and the implementation of the present invention, and the description of the above embodiment is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.