CN110633219A - Page testing method and device, storage medium and electronic equipment - Google Patents
Page testing method and device, storage medium and electronic equipment Download PDFInfo
- Publication number
- CN110633219A CN110633219A CN201910907519.0A CN201910907519A CN110633219A CN 110633219 A CN110633219 A CN 110633219A CN 201910907519 A CN201910907519 A CN 201910907519A CN 110633219 A CN110633219 A CN 110633219A
- Authority
- CN
- China
- Prior art keywords
- page
- tested
- target test
- component
- interface
- 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.)
- Granted
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Prevention of errors by analysis, debugging or testing of software
- G06F11/3668—Testing of software
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
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)
- Debugging And Monitoring (AREA)
Abstract
The disclosure belongs to the technical field of computers, and relates to a page testing method and device, a computer readable storage medium and electronic equipment. The method comprises the following steps: establishing a simulation interface and acquiring interface parameters of the simulation interface; taking the interface parameter as a request path, and acquiring a page component to be tested corresponding to the interface parameter; and replacing the page component to be tested with a target test page component to generate a target test page containing the target test page component, and testing. According to the method and the device, the target test page can be generated and tested in a mode of replacing the page component to be tested with the target test page component. On one hand, the testing process is simple, page codes do not need to be modified, and workload and testing risk are reduced; on the other hand, the method is suitable for local area networks and wide area networks, improves the practicability and enlarges the test range.
Description
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a page testing method, a page testing apparatus, a computer-readable storage medium, and an electronic device.
Background
Today, all functions or activities performed at each end client are implemented using embedded pages. Thus, there may be some common functions, Software Development Kit (SDK) or styles for each page that are extracted as JavaScript components or Cascading Style Sheets (CSS) styles for pages to reference directly through scripts or Link tags.
When the component is updated, the performance of the component on each page needs to be returned in the test, namely, the component file referenced by each page needs to be replaced by a test version, if each page is changed, the influence is too large and is not reasonable, and the page in the client cannot be captured by a Fildlle tool.
In view of this, there is a need in the art to develop a new page testing method and apparatus.
It is to be noted that the information disclosed in the above background section is only for enhancement of understanding of the background of the present disclosure, and thus may include information that does not constitute prior art known to those of ordinary skill in the art.
Disclosure of Invention
The disclosure aims to provide a page testing method, a page testing device, a computer readable storage medium and an electronic device, so as to overcome the problems of too large page modification, incapability of grabbing requests and the like caused by the limitation of related technologies at least to a certain extent.
Additional features and advantages of the disclosure will be set forth in the detailed description which follows, or in part will be obvious from the description, or may be learned by practice of the disclosure.
According to one aspect of the present disclosure, there is provided a page testing method, the method including: creating a simulation interface and acquiring interface parameters of the simulation interface; taking the interface parameter as a request path, and acquiring a page component to be tested corresponding to the interface parameter; and replacing the page component to be tested with a target test page component to generate a target test page containing the target test page component, and testing.
In an exemplary embodiment of the present disclosure, after the generating the target test page including the target test page component, the method further includes: returning the target test page to the interface parameters; and starting a local server, and acquiring the target test page according to the interface parameters so as to test the target test page.
In an exemplary embodiment of the disclosure, before the creating of the analog interface, the method further comprises: building the local server; and configuring the local domain name of the local server to determine the page for creating the simulation interface.
In an exemplary embodiment of the present disclosure, the port of the local server proxy is an 80 port.
In an exemplary embodiment of the disclosure, the replacing the page component to be tested with a target test page component includes: matching the information of the to-be-tested components of the to-be-tested page components with the information of the target testing components of the target testing page components to determine whether the to-be-tested page components and the target testing page components are successfully matched; and if the page component to be tested is successfully matched with the target test page component, replacing the page component to be tested with the target test page component.
In an exemplary embodiment of the present disclosure, the information of the page components to be tested includes a name of the page component to be tested, and an identifier of the page component to be tested; the target test component information comprises the name of the target test page component and the identification of the target test page component.
In an exemplary embodiment of the present disclosure, the simulation interface includes a get interface.
According to an aspect of the present disclosure, there is provided a page testing apparatus, the apparatus including: the system comprises an address acquisition module, a simulation module and a control module, wherein the address acquisition module is configured to create a simulation interface and acquire interface parameters of the simulation interface; the component acquisition module is configured to acquire a to-be-tested page component corresponding to the interface parameter by taking the interface parameter as a request path; and the page generation module is configured to replace the page component to be tested with a target test page component so as to generate a target test page containing the target test page component and perform testing.
According to an aspect of the present disclosure, there is provided an electronic device including: a processor and a memory; wherein the memory has stored thereon computer readable instructions which, when executed by the processor, implement the page testing method of any of the above exemplary embodiments.
According to an aspect of the present disclosure, there is provided a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the page testing method in any of the above-described exemplary embodiments.
As can be seen from the foregoing technical solutions, the page testing method, the page testing apparatus, the computer storage medium and the electronic device in the exemplary embodiments of the present disclosure have at least the following advantages and positive effects:
in the method and the device provided by the exemplary embodiment of the disclosure, the target test page can be generated and tested by replacing the page component to be tested with the target test page component. On one hand, the testing process is simple, page codes do not need to be modified, and workload and testing risk are reduced; on the other hand, the method is suitable for local area networks and wide area networks, improves the practicability and enlarges the test range.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure. It is to be understood that the drawings in the following description are merely exemplary of the disclosure, and that other drawings may be derived from those drawings by one of ordinary skill in the art without the exercise of inventive faculty.
FIG. 1 schematically illustrates a flow chart of a page testing method in an exemplary embodiment of the present disclosure;
FIG. 2 is a flow diagram schematically illustrating a method for replacing a page component to be tested in an exemplary embodiment of the present disclosure;
FIG. 3 is a schematic flow chart diagram illustrating a method for testing a target test page in an exemplary embodiment of the present disclosure;
FIG. 4 schematically illustrates a flow chart of a method of configuring a local server in an exemplary embodiment of the disclosure;
FIG. 5 is a schematic flow chart illustrating a prior art page testing method;
FIG. 6 is a schematic flow chart illustrating another prior art page testing method;
FIG. 7 is a flowchart illustrating a page testing method in an application scenario according to an exemplary embodiment of the present disclosure;
FIG. 8 is a schematic flow chart diagram illustrating a method of testing a target test page in an exemplary embodiment of the present disclosure;
FIG. 9 is a schematic structural diagram of a page testing apparatus according to an exemplary embodiment of the disclosure;
FIG. 10 schematically illustrates an electronic device for implementing a page test method in an exemplary embodiment of the present disclosure;
fig. 11 schematically illustrates a computer-readable storage medium for implementing a page test method in an exemplary embodiment of the disclosure.
Detailed Description
Example embodiments will now be described more fully with reference to the accompanying drawings. Example embodiments may, however, be embodied in many different forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the concept of example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. In the following description, numerous specific details are provided to give a thorough understanding of embodiments of the disclosure. One skilled in the relevant art will recognize, however, that the subject matter of the present disclosure can be practiced without one or more of the specific details, or with other methods, components, devices, steps, and the like. In other instances, well-known technical solutions have not been shown or described in detail to avoid obscuring aspects of the present disclosure.
The terms "a," "an," "the," and "said" are used in this specification to denote the presence of one or more elements/components/parts/etc.; the terms "comprising" and "having" are intended to be inclusive and mean that there may be additional elements/components/etc. other than the listed elements/components/etc.; the terms "first" and "second", etc. are used merely as labels, and are not limiting on the number of their objects.
Furthermore, the drawings are merely schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the drawings denote the same or similar parts, and thus their repetitive description will be omitted. Some of the block diagrams shown in the figures are functional entities and do not necessarily correspond to physically or logically separate entities.
Aiming at the problems in the related art, the disclosure provides a page testing method. Fig. 1 shows a flow chart of a page testing method, as shown in fig. 1, the page testing method at least includes the following steps:
and S110, establishing a simulation interface and acquiring interface parameters of the simulation interface.
And S120, acquiring the page component to be tested corresponding to the interface parameter by taking the interface parameter as a request path.
And S130, replacing the page component to be tested with a target test page component to generate a target test page containing the target test page component, and testing.
In the exemplary embodiment of the present disclosure, a target test page may be generated and tested by replacing a page component to be tested with a target test page component. On one hand, the testing process is simple, page codes do not need to be modified, and workload and testing risk are reduced; on the other hand, the method is suitable for local area networks and wide area networks, improves the practicability and enlarges the test range.
The individual steps of the page testing method are explained in detail below.
In step S110, a simulation interface is created, and interface parameters of the simulation interface are acquired.
In an exemplary embodiment of the present disclosure, several different operation modes for requesting resources are defined in a HyperText Transfer Protocol (HTTP), including a post mode and a get mode. Considering that the get mode is the most common one of the operation modes, an emulation interface is created to perform the get operation. In an alternative embodiment, the simulation interface comprises a get interface. And operating through the get interface to realize the function of requesting the resource. In addition, the analog interface may be other analog interfaces, which is not limited in this exemplary embodiment.
After the emulated interface is created, the interface parameters brought along when the emulated interface is requested may be obtained. For example, the interface parameter may be a go parameter, which is a page address of a page to be tested. In addition, the interface parameter may also be other interface parameters acquired when the request is made, which is not particularly limited in this exemplary embodiment.
In step S120, the interface parameter is taken as a request path to obtain a to-be-tested page component corresponding to the interface parameter.
In an exemplary embodiment of the present disclosure, an HTTP request may be initiated by using the go parameter as a request path, and a page component of a returned page to be tested, that is, content of hypertext Markup Language (HTML) is obtained. The page components may include various common interface components, such as tables, trees, linked drop-down boxes, and the like, and construct various page modules. Generally, the page components may include, but are not limited to, a Template (Template, abbreviated to "tpl") component, a Cascading Style Sheets (CSS) component, a JavaScript component, and other page components, which is not limited in this exemplary embodiment.
In step S130, the page component to be tested is replaced with the target test page component to generate a target test page including the target test page component, and the target test page is tested.
In an exemplary embodiment of the present disclosure, fig. 2 shows a flow diagram of a method of replacing a page component to be tested, which, as shown in fig. 2, comprises at least the following steps: in step S210, matching the to-be-tested component information of the to-be-tested page component with the target test component information of the target test page component to determine whether the to-be-tested page component and the target test page component are successfully matched. The electronic equipment running the page testing method of the scheme can match the information of the components to be tested with the information of the target testing components.
In an optional embodiment, the information of the to-be-tested components includes names of the to-be-tested page components and identifications of the to-be-tested page components; the target test component information comprises the name of the target test page component and the identification of the target test page component. The information of the to-be-tested components can also comprise the names of the page modules to which the to-be-tested page components belong and the identifications of the page modules to which the to-be-tested page components belong; correspondingly, the target test component information may further include the name of the page module to which the target test page component belongs and the identifier of the page module to which the target test page component belongs. In addition, the page component information to be tested and the target test page component information may also include component information of other page components to be tested and component information of other target test page components, which is not particularly limited in this exemplary embodiment.
In step S220, if the page component to be tested is successfully matched with the target test page component, the page component to be tested is replaced with the target test page component. For example, when the information of the to-be-tested component of the to-be-tested page component is the same as the information of the target test component of the target test page component, it may be determined that the to-be-tested page component and the target test page component are successfully matched. In addition, when the page component to be tested and the target test page component meet the preset conditions of the information of the component to be tested and the information of the target test component, it may be determined that the page component to be tested and the target test page component are successfully matched, and the matching may also be determined to be successful through other matching conditions, which is not particularly limited in this exemplary embodiment.
When the page component to be tested is successfully matched with the target test page component, the function of replacing the page component to be tested with the target test page component can be realized by replacing the address of the page component to be tested with the address of the target test page. In addition, other alternatives are also possible, and the present exemplary embodiment is not particularly limited thereto.
In the exemplary embodiment, the successfully matched page component to be tested is replaced by the target test page component, the function of the target test page can be achieved subsequently, the matching mode is accurate, the replacement mode is simple, the page code does not need to be changed, the workload and the risk are reduced, and the practicability is strong.
After replacing the page component to be tested with the target test page component, a target test page including the target test page component may be generated to test the target test page.
In an alternative embodiment, fig. 3 shows a flowchart of a method for testing a target test page, and as shown in fig. 3, the method at least includes the following steps: in step S310, the target test page is returned to the interface parameters. The generated HTML of the target test page can be returned to the interface parameter as a result of the request, that is, the go parameter is the page address of the target test page.
In step S320, the local server is started, and the target test page is obtained according to the interface parameters to test the target test page. The local server may be a server that can only be accessed by devices of the internal local area network. And the target test page can be tested through the opened test page of the target test page.
In the present exemplary embodiment, the target test page may be tested by the test page of the local service to determine the test result.
Other configurations of the local server may also be performed prior to creating the simulation interface. In an alternative embodiment, fig. 4 shows a flow chart of a method for configuring a local server, as shown in fig. 4, the method at least includes the following steps: in step S410, a local server is set up. The local server may be a server built by node. Js is an execution environment of an transliterated script language (JavaScript). In view of the fact that the development mode of the existing world wide Web (Web for short) is a front-end and back-end coupling mode, the front-end building of the local server can enable the server to operate independently of the front-end, and enable the front-end to execute commands depending on the local server, so that the control of the back-end is separated, and the page test is facilitated.
In an alternative embodiment, the port of the home server agent is an 80 port. The 80 port is an open port of HHTP, and the default port numbers of the browsing web page server are all 80, so that only the page website of the test page needs to be input in the subsequent test page without inputting ": 80".
In step S420, the local domain name of the local server is configured to determine the page on which the emulated interface is created. The service domain name is bound with an Internet Protocol Address (IP), and a local domain name can be obtained to provide local service, so that an HTTP webpage can access the service across domains. For example, the service domain name may be test.cc.163.com, and the local IP may be 127.0.0.1, i.e., test.cc.163.com is bound to 127.0.0.0.1, resulting in a local domain name of 127.0.0.1 test.cc.163.com. Where test.cc.163.com is the sub-domain name of www.test.cc.163.com, subsequent page test operations can be directed to the local service by the sub-domain name of the test page being established.
In the exemplary embodiment, the subsequent steps of the subsequent page testing method can be realized through the built local server, the creation mode is simple, the subsequent page testing method is not influenced by other factors, and the testing accuracy is ensured.
The following describes the page testing method in the embodiment of the present disclosure in detail with reference to an application scenario.
FIG. 5 is a flowchart illustrating a prior art page testing method, and as shown in FIG. 5, after a page to be tested is selected, an address of a page component in the page to be tested is directly modified to a test version; the modified page components are then tested. If the test fails, repairing the defective page assembly and continuing the test; and if the test is passed, withdrawing the modification of the component address referenced by the page to be tested, and finishing the test. It can be seen that the test method needs to change the component reference code of the page to be tested, the workload is large, and regression cannot be tested.
Fig. 6 is a schematic flow chart of another prior art page testing method, as shown in fig. 6, after a page to be tested is selected, the testing is performed directly. If the test fails, repairing the defective page assembly and continuing the test; and if the test is passed, the test is finished. Although the method directly tests the local area network without additionally changing page codes, the local area network quotes a version which is not the latest stable external network, so that the defects of different internal and external network performances are easy to occur, and the regression cannot be tested.
Fig. 7 is a schematic flowchart illustrating a page testing method in an application scenario, where as shown in fig. 7, a get interface is created, and a go parameter carried by a request, that is, a page address to be tested, is read; and then, initiating an HTTP request by taking the go parameter as a request path, reading the page component to be tested, and replacing the page component to be tested with a target test page component. For example, the replacement between the components can be completed by replacing the address of the page component to be tested with the address of the target test page. And finally, returning the generated target test page containing the target test page component as a request result.
Fig. 8 is a flowchart illustrating a method for testing a target test page in an application scenario, where as shown in fig. 8, a local server is started, and a target test page is opened on the test page. After the target test page is selected, a command can be input and executed in the page console, and the test result of the target test page is judged according to the execution result. If the test fails, repairing the defective page assembly and continuing the test; and if the test is passed, the test is finished.
In the exemplary embodiment of the present disclosure, a target test page may be generated and tested by replacing a page component to be tested with a target test page component. On one hand, the testing process is simple, page codes do not need to be modified, and workload and testing risk are reduced; on the other hand, the method is suitable for local area networks and wide area networks, improves the practicability and enlarges the test range.
It should be noted that although the above exemplary embodiment implementations describe the various steps of the method in the present disclosure in a particular order, this does not require or imply that these steps must be performed in that particular order, or that all of the steps must be performed, to achieve the desired results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions, etc.
In addition, in an exemplary embodiment of the present disclosure, a page testing apparatus is also provided. Fig. 9 shows a schematic structural diagram of the page testing apparatus, and as shown in fig. 9, the page testing apparatus 900 may include: address acquisition module 910, component acquisition module 920, and page generation module 930. Wherein:
an address obtaining module 910 configured to create a simulation interface and obtain interface parameters of the simulation interface; the component obtaining module 920 is configured to obtain a to-be-tested page component corresponding to the interface parameter by using the interface parameter as a request path; the page generating module 930 is configured to replace the page component to be tested with the target test page component, so as to generate a target test page including the target test page component, and perform a test.
The specific details of the page testing apparatus have been described in detail in the corresponding page testing method, and therefore are not described herein again.
It should be noted that although several modules or units of the page testing apparatus 900 are mentioned in the above detailed description, such division is not mandatory. Indeed, the features and functionality of two or more modules or units described above may be embodied in one module or unit, according to embodiments of the present disclosure. Conversely, the features and functions of one module or unit described above may be further divided into embodiments by a plurality of modules or units.
Moreover, although the steps of the methods of the present disclosure are depicted in the drawings in a particular order, this does not require or imply that the steps must be performed in this particular order, or that all of the depicted steps must be performed, to achieve desirable results. Additionally or alternatively, certain steps may be omitted, multiple steps combined into one step execution, and/or one step broken down into multiple step executions, etc.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
In addition, in an exemplary embodiment of the present disclosure, an electronic device capable of implementing the above method is also provided.
An electronic device 1000 according to such an embodiment of the invention is described below with reference to fig. 10. The electronic device 1000 shown in fig. 10 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 10, the electronic device 1000 is embodied in the form of a general purpose computing device. The components of the electronic device 1000 may include, but are not limited to: the at least one processing unit 1010, the at least one memory unit 1020, a bus 1030 connecting different system components (including the memory unit 1020 and the processing unit 1010), and a display unit 1040.
Wherein the storage unit stores program code that is executable by the processing unit 1010 to cause the processing unit 1010 to perform steps according to various exemplary embodiments of the present invention as described in the "exemplary methods" section above in this specification.
The memory unit 1020 may include readable media in the form of volatile memory units, such as a random access memory unit (RAM)1021 and/or a cache memory unit 1022, and may further include a read-only memory unit (ROM) 1023.
Storage unit 1020 may also include a program/utility 1024 having a set (at least one) of program modules 1025, such program modules 1025 including, but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which, or some combination thereof, may comprise an implementation of a network environment.
Bus 1030 may be any one or more of several types of bus structures including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, and a local bus using any of a variety of bus architectures.
The electronic device 1000 may also communicate with one or more external devices 1200 (e.g., keyboard, pointing device, bluetooth device, etc.), with one or more devices that enable a user to interact with the electronic device 1000, and/or with any devices (e.g., router, modem, etc.) that enable the electronic device 1000 to communicate with one or more other computing devices. Such communication may occur through input/output (I/O) interfaces 1050. Also, the electronic device 1000 may communicate with one or more networks (e.g., a Local Area Network (LAN), a Wide Area Network (WAN), and/or a public network such as the internet) via the network adapter 1060. As shown, the network adapter 1040 communicates with other modules of the electronic device 1000 via the bus 1030. It should be appreciated that although not shown, other hardware and/or software modules may be used in conjunction with the electronic device 1000, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, among others.
Through the above description of the embodiments, those skilled in the art will readily understand that the exemplary embodiments described herein may be implemented by software, or by software in combination with necessary hardware. Therefore, the technical solution according to the embodiments of the present disclosure may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which may be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the embodiments of the present disclosure.
In an exemplary embodiment of the present disclosure, there is also provided a computer-readable storage medium having stored thereon a program product capable of implementing the above-described method of the present specification. In some possible embodiments, aspects of the invention may also be implemented in the form of a program product comprising program code means for causing a terminal device to carry out the steps according to various exemplary embodiments of the invention described in the above-mentioned "exemplary methods" section of the present description, when said program product is run on the terminal device.
Referring to fig. 11, a program product 1100 for implementing the above method according to an embodiment of the present invention is described, which may employ a portable compact disc read only memory (CD-ROM) and include program code, and may be run on a terminal device, such as a personal computer. However, the program product of the present invention is not limited in this regard and, in the present document, a readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device.
The program product may employ any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. A readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples (a non-exhaustive list) of the readable storage medium include: an electrical connection having one or more wires, a portable disk, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
A computer readable signal medium may include a propagated data signal with readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A readable signal medium may also be any readable medium that is not a readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device.
Program code embodied on a readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
Program code for carrying out operations for aspects of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, C + + or the like and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computing device, partly on the user's device, as a stand-alone software package, partly on the user's computing device and partly on a remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any kind of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or may be connected to an external computing device (e.g., through the internet using an internet service provider).
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
Claims (10)
1. A page testing method is characterized by comprising the following steps:
creating a simulation interface and acquiring interface parameters of the simulation interface;
taking the interface parameter as a request path, and acquiring a page component to be tested corresponding to the interface parameter;
and replacing the page component to be tested with a target test page component to generate a target test page containing the target test page component, and testing.
2. The method for page testing of claim 1, wherein after said generating a target test page containing said target test page components, said method further comprises:
returning the target test page to the interface parameters;
and starting a local server, and acquiring the target test page according to the interface parameters so as to test the target test page.
3. The page testing method of claim 2, wherein prior to said creating a simulation interface, said method further comprises:
building the local server;
and configuring the local domain name of the local server to determine the page for creating the simulation interface.
4. The page testing method according to claim 3,
the port of the home server agent is an 80 port.
5. The page testing method according to claim 1, wherein said replacing the page component to be tested with a target test page component comprises:
matching the information of the to-be-tested components of the to-be-tested page components with the information of the target testing components of the target testing page components to determine whether the to-be-tested page components and the target testing page components are successfully matched;
and if the page component to be tested is successfully matched with the target test page component, replacing the page component to be tested with the target test page component.
6. The page testing method according to claim 5,
the information of the page components to be tested comprises the names of the page components to be tested and the identifications of the page components to be tested;
the target test component information comprises the name of the target test page component and the identification of the target test page component.
7. The page testing method according to claim 1,
the simulation interface comprises a get interface.
8. A page testing apparatus, comprising:
the system comprises an address acquisition module, a simulation module and a control module, wherein the address acquisition module is configured to create a simulation interface and acquire interface parameters of the simulation interface;
the component acquisition module is configured to acquire a to-be-tested page component corresponding to the interface parameter by taking the interface parameter as a request path;
and the page generation module is configured to replace the page component to be tested with a target test page component so as to generate a target test page containing the target test page component and perform testing.
9. A computer-readable storage medium, on which a computer program is stored, which, when being executed by a transmitter, carries out the page testing method of any one of claims 1 to 7.
10. An electronic device, comprising:
a transmitter;
a memory for storing executable instructions of the transmitter;
wherein the transmitter is configured to perform the page testing method of any of claims 1-7 via execution of the executable instructions.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910907519.0A CN110633219B (en) | 2019-09-24 | 2019-09-24 | Page test method and device, storage medium and electronic equipment |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201910907519.0A CN110633219B (en) | 2019-09-24 | 2019-09-24 | Page test method and device, storage medium and electronic equipment |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| CN110633219A true CN110633219A (en) | 2019-12-31 |
| CN110633219B CN110633219B (en) | 2023-09-08 |
Family
ID=68973662
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201910907519.0A Active CN110633219B (en) | 2019-09-24 | 2019-09-24 | Page test method and device, storage medium and electronic equipment |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN110633219B (en) |
Cited By (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111538667A (en) * | 2020-04-28 | 2020-08-14 | 北京三快在线科技有限公司 | Page testing method and device |
| CN111597110A (en) * | 2020-04-27 | 2020-08-28 | 五八有限公司 | Page testing method and device, electronic equipment and storage medium |
| CN111682979A (en) * | 2020-05-28 | 2020-09-18 | 杭州迪普科技股份有限公司 | Method and device for generating high-speed signal test board |
| CN111782291A (en) * | 2020-06-12 | 2020-10-16 | 京东数字科技控股有限公司 | Test page starting method and device |
| CN114090139A (en) * | 2020-07-29 | 2022-02-25 | 北京字节跳动网络技术有限公司 | Page processing method and device, electronic equipment and computer readable storage medium |
| CN114138664A (en) * | 2021-12-09 | 2022-03-04 | 拉扎斯网络科技(上海)有限公司 | Page testing method and device, storage medium and computer equipment |
| CN114328246A (en) * | 2021-12-30 | 2022-04-12 | 北京百度网讯科技有限公司 | A method, device, equipment and storage medium for determining the scope of software testing |
Citations (11)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20100325615A1 (en) * | 2009-06-23 | 2010-12-23 | Myspace Inc. | Method and system for capturing web-page information through web-browser plugin |
| CN105955888A (en) * | 2016-05-04 | 2016-09-21 | 腾讯科技(深圳)有限公司 | Page debugging and previewing method and system |
| CN106354622A (en) * | 2015-07-14 | 2017-01-25 | 北京国双科技有限公司 | Exhibiting method of test webpage and device |
| CN107133180A (en) * | 2017-06-07 | 2017-09-05 | 腾讯科技(深圳)有限公司 | Method of testing, test device and the storage medium of dynamic page |
| CN107256195A (en) * | 2017-06-08 | 2017-10-17 | 武汉斗鱼网络科技有限公司 | Webpage front-end method of testing and device |
| CN108255730A (en) * | 2018-01-23 | 2018-07-06 | 平安普惠企业管理有限公司 | Software interface test approach, test equipment, storage medium and device |
| CN108255847A (en) * | 2016-12-28 | 2018-07-06 | 腾讯科技(深圳)有限公司 | Page generation method and device |
| CN109408387A (en) * | 2018-10-24 | 2019-03-01 | 天津字节跳动科技有限公司 | Page test method and device |
| CN109408372A (en) * | 2018-09-26 | 2019-03-01 | 平安普惠企业管理有限公司 | Common component test method, device, computer equipment and storage medium |
| CN109634839A (en) * | 2018-10-25 | 2019-04-16 | 深圳壹账通智能科技有限公司 | Page test method and device, storage medium, electric terminal |
| CN110046101A (en) * | 2019-04-15 | 2019-07-23 | 腾讯音乐娱乐科技(深圳)有限公司 | Page automated testing method, device and computer storage medium |
-
2019
- 2019-09-24 CN CN201910907519.0A patent/CN110633219B/en active Active
Patent Citations (11)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20100325615A1 (en) * | 2009-06-23 | 2010-12-23 | Myspace Inc. | Method and system for capturing web-page information through web-browser plugin |
| CN106354622A (en) * | 2015-07-14 | 2017-01-25 | 北京国双科技有限公司 | Exhibiting method of test webpage and device |
| CN105955888A (en) * | 2016-05-04 | 2016-09-21 | 腾讯科技(深圳)有限公司 | Page debugging and previewing method and system |
| CN108255847A (en) * | 2016-12-28 | 2018-07-06 | 腾讯科技(深圳)有限公司 | Page generation method and device |
| CN107133180A (en) * | 2017-06-07 | 2017-09-05 | 腾讯科技(深圳)有限公司 | Method of testing, test device and the storage medium of dynamic page |
| CN107256195A (en) * | 2017-06-08 | 2017-10-17 | 武汉斗鱼网络科技有限公司 | Webpage front-end method of testing and device |
| CN108255730A (en) * | 2018-01-23 | 2018-07-06 | 平安普惠企业管理有限公司 | Software interface test approach, test equipment, storage medium and device |
| CN109408372A (en) * | 2018-09-26 | 2019-03-01 | 平安普惠企业管理有限公司 | Common component test method, device, computer equipment and storage medium |
| CN109408387A (en) * | 2018-10-24 | 2019-03-01 | 天津字节跳动科技有限公司 | Page test method and device |
| CN109634839A (en) * | 2018-10-25 | 2019-04-16 | 深圳壹账通智能科技有限公司 | Page test method and device, storage medium, electric terminal |
| CN110046101A (en) * | 2019-04-15 | 2019-07-23 | 腾讯音乐娱乐科技(深圳)有限公司 | Page automated testing method, device and computer storage medium |
Non-Patent Citations (1)
| Title |
|---|
| SUNNYYOU2011: "软件web测试之url测试(含POST 、GET)", pages 1, Retrieved from the Internet <URL:《https://blog.csdn.net/Sunnyyou2011/article/details/40042839》> * |
Cited By (10)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN111597110A (en) * | 2020-04-27 | 2020-08-28 | 五八有限公司 | Page testing method and device, electronic equipment and storage medium |
| CN111597110B (en) * | 2020-04-27 | 2024-02-27 | 五八有限公司 | Page test method and device, electronic equipment and storage medium |
| CN111538667A (en) * | 2020-04-28 | 2020-08-14 | 北京三快在线科技有限公司 | Page testing method and device |
| CN111682979A (en) * | 2020-05-28 | 2020-09-18 | 杭州迪普科技股份有限公司 | Method and device for generating high-speed signal test board |
| CN111682979B (en) * | 2020-05-28 | 2021-12-07 | 杭州迪普科技股份有限公司 | Method and device for generating high-speed signal test board |
| CN111782291A (en) * | 2020-06-12 | 2020-10-16 | 京东数字科技控股有限公司 | Test page starting method and device |
| CN111782291B (en) * | 2020-06-12 | 2024-06-18 | 京东科技控股股份有限公司 | Method and device for starting test page |
| CN114090139A (en) * | 2020-07-29 | 2022-02-25 | 北京字节跳动网络技术有限公司 | Page processing method and device, electronic equipment and computer readable storage medium |
| CN114138664A (en) * | 2021-12-09 | 2022-03-04 | 拉扎斯网络科技(上海)有限公司 | Page testing method and device, storage medium and computer equipment |
| CN114328246A (en) * | 2021-12-30 | 2022-04-12 | 北京百度网讯科技有限公司 | A method, device, equipment and storage medium for determining the scope of software testing |
Also Published As
| Publication number | Publication date |
|---|---|
| CN110633219B (en) | 2023-09-08 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN110633219B (en) | Page test method and device, storage medium and electronic equipment | |
| US9218269B2 (en) | Testing multiple target platforms | |
| US8375362B1 (en) | Wizard for web service search adapter | |
| US20130254139A1 (en) | Systems and methods for building a universal intelligent assistant with learning capabilities | |
| CN110858172B (en) | A method and device for generating automatic test code | |
| CN113761428B (en) | Page rendering method, device, system, storage medium and electronic device | |
| CN103729285A (en) | Method, device and system for testing web page | |
| CN112269739B (en) | Webpage testing method and device, equipment and medium thereof | |
| CN111949522A (en) | User interface automatic testing method and device | |
| CN110727429B (en) | Front-end page generation method, device and equipment | |
| CN111241111A (en) | Data query method and device, data comparison method and device, medium and equipment | |
| CN113419711A (en) | Page guiding method and device, electronic equipment and storage medium | |
| CN109783355A (en) | Page elements acquisition methods, system, computer equipment and readable storage medium storing program for executing | |
| CN113268407A (en) | Page testing method and device, computer storage medium and electronic equipment | |
| CN104317570A (en) | Device and method for dynamically analyzing web application | |
| CN109614325B (en) | Method and device for determining control attribute, electronic equipment and storage medium | |
| CN113778897A (en) | Automatic test method, device, equipment and storage medium of interface | |
| CN112491940B (en) | Request forwarding method and device of proxy server, storage medium and electronic equipment | |
| CN104270443A (en) | Cloud computing system and method capable of dynamically analyzing Web application | |
| CN114816672A (en) | Virtual machine creation method and device, electronic equipment and storage medium | |
| CN111857752B (en) | PostgreSQL database installation method, device and equipment | |
| CN111158645B (en) | System and method for providing an integrated development environment | |
| CN113190462A (en) | Dynamic data debugging method, device and equipment | |
| CN112528193B (en) | Page copy processing method, page copy management method, device, terminal equipment, computer equipment and server | |
| CN105912573A (en) | Data updating method and data updating device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| PB01 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| GR01 | Patent grant | ||
| GR01 | Patent grant |