CN108427633B - Display interface processing method and device - Google Patents
Display interface processing method and device Download PDFInfo
- Publication number
- CN108427633B CN108427633B CN201710081534.5A CN201710081534A CN108427633B CN 108427633 B CN108427633 B CN 108427633B CN 201710081534 A CN201710081534 A CN 201710081534A CN 108427633 B CN108427633 B CN 108427633B
- Authority
- CN
- China
- Prior art keywords
- display interface
- interface
- terminal
- abnormal
- popup
- 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.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/36—Preventing errors by testing or debugging software
- G06F11/3668—Software testing
- G06F11/3672—Test management
- G06F11/3688—Test management for test execution, e.g. scheduling of test suites
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)
- User Interface Of Digital Computer (AREA)
Abstract
The invention discloses a method and a device for processing a display interface, wherein the method comprises the following steps: the method comprises the steps that in the process of testing an application client to be tested on a terminal, characteristic parameters of a first display interface displayed on the uppermost layer of the terminal are obtained; judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface; and under the condition that the first display interface is judged to be the abnormal popup interface, closing the first display interface, and displaying a test interface for testing the application client at the uppermost layer of the terminal. The problem of need manually carry out a large amount of closing operations to close unusual popup among the prior art is solved, a large amount of human costs have both been saved, unusual popup can in time be handled again, the processing of effectively avoiding omitting unusual popup, and then the success rate and the efficiency of the automatic testing of application client on the terminal have been improved greatly.
Description
Technical Field
The invention relates to the field of computers, in particular to a display interface processing method and device.
Background
At present, in the process of automatically testing an application client to be tested on a terminal, unpredictable abnormal popup windows exist in the process of executing a script, and the abnormal popup windows can intercept all click/sliding events in the test, so that a normal test flow cannot be carried out.
For example, a test script for testing the instant messaging application client a installed in a mobile phone is automatically executed in a plurality of mobile phones at the same time. In the test process, the mobile phone B pops up an authority prompt window, and the prompt window displays that whether the instant communication application client A requests the recording authority or not. At this time, if the prompt window is closed without performing a correct operation on the current prompt window, the subsequent test cannot be continuously performed in the mobile phone B, thereby causing a test failure. In the prior art, the prompt window is closed manually. However, in a scenario of automatically executing a test script in thousands of mobile phones, it often happens that a plurality of mobile phones pop up the permission prompt windows at the same time, so that a tester needs to manually execute a large amount of closing operations, and may fail to close all the prompt windows in time, thereby reducing the testing efficiency.
In view of the above problems in the prior art, no effective solution has been proposed.
Disclosure of Invention
The embodiment of the invention provides a processing method and a processing device for a display interface, which are used for at least solving the problem that a large amount of closing operations need to be manually executed to close abnormal popup windows in the prior art.
According to an aspect of the embodiments of the present invention, there is provided a method for processing a display interface, including: the method comprises the steps that in the process of testing an application client to be tested on a terminal, characteristic parameters of a first display interface displayed on the uppermost layer of the terminal are obtained; judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface; and under the condition that the first display interface is judged to be the abnormal popup interface, closing the first display interface, and displaying a test interface for testing the application client at the uppermost layer of the terminal.
According to another aspect of the embodiments of the present invention, there is also provided a processing apparatus for displaying an interface, including: the system comprises an acquisition module, a display module and a display module, wherein the acquisition module is used for acquiring characteristic parameters of a first display interface displayed on the uppermost layer of a terminal in the process of testing an application client to be tested on the terminal; the judging module is used for judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface; the closing module is used for closing the first display interface under the condition that the first display interface is judged to be the abnormal popup interface; and the display module is used for displaying a test interface for testing the application client on the uppermost layer of the terminal.
In the embodiment of the invention, in the process of testing the application client to be tested on the terminal, the terminal can automatically acquire the characteristic parameters of the first display interface displayed at the uppermost layer of the terminal, judge whether the first display interface is an abnormal popup interface or not according to the acquired characteristic parameters, automatically close the current first display interface if the first display interface displayed at the uppermost layer is judged to be the abnormal popup interface, and return to the test interface for testing the application client. By the method, the terminal automatically acquires the characteristic parameters of the uppermost display interface and judges whether the uppermost display interface is the abnormal popup interface according to the acquired characteristic parameters, so that the abnormal popup interface can be automatically identified and closed, the problem that a large amount of closing operations need to be manually executed to close the abnormal popup in the prior art is solved, a large amount of labor cost is saved, the abnormal popup can be timely processed, the processing of the abnormal popup is effectively avoided being omitted, and the success rate and the efficiency of automatic testing of the application client on the terminal are greatly improved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the invention without limiting the invention. In the drawings:
FIG. 1 is a schematic diagram of an application environment of an alternative method for processing a display interface according to an embodiment of the present invention;
FIG. 2 is a flow chart of an alternative method of processing a display interface according to an embodiment of the invention;
FIG. 3 is a block diagram of an alternative exception popup interface according to an embodiment of the present invention;
FIG. 4 is a block diagram illustrating an alternative exception pop-up interface and operation options according to an embodiment of the present invention;
FIG. 5 is a schematic diagram of yet another alternative display interface processing method according to an embodiment of the invention;
FIG. 6 is a schematic diagram of yet another alternative display interface processing method according to an embodiment of the invention;
FIG. 7 is a schematic diagram of yet another alternative display interface processing method according to an embodiment of the invention;
FIG. 8 is a block diagram of an alternative display interface processing device according to an embodiment of the invention;
FIG. 9 is a block diagram of an alternative display interface processing device according to an embodiment of the invention;
FIG. 10 is a flowchart of yet another alternative method for processing a display interface, according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions of the present invention better understood, 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.
It should be noted that the terms "first," "second," and the like in the description and claims of the present invention and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the invention described herein are capable of operation in sequences other than those illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Example 1
In an embodiment of the present invention, an embodiment of a processing method for the display interface is provided. Fig. 1 is a schematic application environment diagram of an alternative display interface processing method according to an embodiment of the present invention. As an optional implementation, the processing method of the display interface may be, but is not limited to, applied to an application environment as shown in fig. 1, where an application client 104 for performing an automated test is running on a terminal 102, and in a test process of the application client 104, characteristic parameters of a first display interface displayed on the uppermost layer of the terminal 102 are obtained. Here, the uppermost layer is understood to be the uppermost layer of the display layer. The characteristic parameters of the first display interface may be obtained when the test process is aborted, or may be obtained according to a preset period, or may be obtained at a preset test time, or may be obtained between two adjacent test operations in the test process. After the characteristic parameters of the current first display interface are obtained, whether the current first display interface is an abnormal popup interface is judged, if the current first display interface is judged to be the abnormal popup interface, the first display interface is automatically closed, and a test interface for testing the application client 104 is displayed on the uppermost layer of the terminal 102, which can be understood as returning to the test interface before the abnormal popup interface or possibly jumping to the next operation interface, and the embodiment of the present invention does not limit this.
Optionally, in the embodiment of the present invention, the terminal may include, but is not limited to, at least one of the following: the present invention relates to a mobile phone, a tablet computer, a notebook computer, and other devices capable of performing an application client test, and the embodiments of the present invention are not limited thereto.
Fig. 2 is a flowchart of an alternative method for processing a display interface according to an embodiment of the present invention. According to an embodiment of the present invention, there is provided a method for processing a display interface, as shown in fig. 2, the method including:
s202, acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal in the process of testing the application client to be tested on the terminal;
s204, judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface;
and S206, under the condition that the first display interface is judged to be the abnormal popup interface, closing the first display interface, and displaying a test interface for testing the application client at the uppermost layer of the terminal.
By the method, in the process of testing the application client to be tested on the terminal, the terminal can automatically acquire the characteristic parameters of the first display interface displayed on the uppermost layer of the terminal, judge whether the first display interface is the abnormal popup interface or not according to the acquired characteristic parameters, automatically close the current first display interface if the first display interface displayed on the uppermost layer is judged to be the abnormal popup interface, and return to the test interface for testing the application client. By the method, the problem that a large amount of closing operations need to be manually executed to close the abnormal popup in the prior art is solved, so that a large amount of labor cost is saved, the abnormal popup can be timely processed, processing of the abnormal popup is effectively avoided being omitted, and the success rate of automatic testing of the application client on the terminal is greatly improved.
Optionally, in the embodiment of the present invention, the processing method of the display interface may be applied to, but not limited to, different application clients, for example, a game application client, a shopping application client, a news application client, a video application client, a communication application client, a community space application client, and any other application client that can be installed on a terminal and tested.
Optionally, in an embodiment of the present invention, the first characteristic parameter may include, but is not limited to, at least one of: the transparency value of the first display interface and the area of the first display interface on the screen of the terminal.
It should be noted that the greater the transparency value, the greater the transparency, for example, when the transparency value is 100%, the description is completely transparent, when the transparency value is 0%, the description is opaque, and when the transparency value is 50%, the description is translucent. Generally, most of abnormal pop-ups are pop-ups with translucency or higher transparency, so that whether the abnormal pop-ups are abnormal can be judged according to the transparency value of the display interface. When the transparency of the pop-up window is low, the judgment can be further carried out by combining the occupied area of the display interface on the terminal screen. The abnormal pop-up window does not occupy the whole display screen generally, but is a small window interface, so that whether the abnormal pop-up window is the abnormal pop-up window can be judged according to the size of the display interface. For example, fig. 3 is a schematic structural diagram of an optional abnormal popup interface according to an embodiment of the present invention, and as shown in fig. 3, a test interface of an application client a occupies the size of the whole screen, and an abnormal popup interface appears during a test process, "is an application client C to start a microphone function, is allowed? "show in the uppermost layer, would block ongoing testing. The abnormal popup interface can be displayed in the middle of the terminal screen, the size of the abnormal popup interface is less than one half of the whole terminal display screen, and the transparency can be set to be any value between 0% and 100%.
Optionally, the step S204 may be implemented by at least one of the following:
judging whether the first display interface is an abnormal popup interface or not according to the transparency value of the first display interface;
judging whether the first display interface is an abnormal popup interface or not according to the area occupied by the first display interface on the screen of the terminal;
and judging whether the first display interface is an abnormal popup interface or not according to the transparency value and the area of the first display interface on the screen of the terminal.
Optionally, the determining whether the first display interface is an abnormal pop-up interface according to the transparency value of the first display interface includes: judging whether the transparency value of the first display interface is greater than or equal to a first preset threshold value or not, and judging that the first display interface is an abnormal popup interface when the transparency value of the first display interface is greater than or equal to the first preset threshold value; when the transparency value of the first display interface is smaller than a first preset threshold, it can be determined that the first display interface is not an abnormal popup interface, or further determination can be performed by combining the area occupied by the first display interface on the screen of the terminal.
Optionally, the determining, according to the transparency value and an area occupied by the first display interface on the screen of the terminal, whether the first display interface is an abnormal pop-up interface includes: judging whether the area occupied by the first display interface on the screen of the terminal is smaller than or equal to a second preset threshold or not, and judging that the first display interface is an abnormal popup interface when the area occupied by the first display interface on the screen of the terminal is smaller than or equal to the second preset threshold; when the area occupied by the first display interface on the screen of the terminal is larger than a second preset threshold value, it can be judged that the first display interface is not an abnormal popup interface, and further judgment can be performed by combining the transparency value of the first display interface.
Optionally, the determining, according to the transparency value and an area occupied by the first display interface on the screen of the terminal, whether the first display interface is an abnormal pop-up interface includes: when the transparency value of the first display interface is smaller than a first preset threshold value and the area of the first display interface on the screen of the terminal is smaller than or equal to a second preset threshold value, judging that the first display interface is an abnormal popup interface; when the transparency value of the first display interface is larger than or equal to a first preset threshold value and the area of the first display interface on the screen of the terminal is larger than a second preset threshold value, judging that the first display interface is an abnormal popup interface; and when the transparency value of the first display interface is greater than or equal to a first preset threshold value and the area of the first display interface on the screen of the terminal is less than or equal to a second preset threshold value, judging that the first display interface is an abnormal popup interface.
It should be noted that, the first preset threshold and the second preset threshold may be flexibly set according to a technical level that can be achieved in the related art, which is not limited in the embodiment of the present invention.
Optionally, the action of closing the first display interface in step S206 may be implemented by:
s1, identifying operation options in the first display interface, wherein the operation options comprise one or more options;
s2, searching a target processing instruction corresponding to a target option in the operation options in the stored processing instruction set, wherein the target processing instruction is used for indicating to close the first display interface;
and S3, closing the first display interface according to the target processing instruction.
It should be noted that, identifying the operation options in the first display interface mainly includes identifying operation instruction options, such as "yes", "no", "allow", "reject", "return", "open", "close", and the like, and also includes identifying a close button "x" of an abnormal pop-up window.
The operation instruction option identification here may be to identify a text and an image on the entire first display interface by parsing the text and the image, record positions of the text and the image on the screen, determine a position of the corresponding operation option according to the identified positions of the text and the image, search a processing instruction set stored in the background for processing a target processing instruction of the corresponding operation option, and after the target processing instruction is found, execute a click or slide process of the corresponding operation option according to the target processing instruction, thereby closing the first display interface (i.e., the abnormal pop-up window interface). Fig. 4 is a schematic structural diagram of an optional exception popup interface and operation options according to an embodiment of the present invention. As shown in fig. 4, the current interface may include click operation options "allow" and "deny" and may also include slide operation options, such as "slide bar to right close" below.
The operation instruction identifying option here may also be that the terminal identifies a background processing program corresponding to each operation option by identifying a background program corresponding to the current pop-up window interface, so as to know which operation option corresponds to the background program for closing the current abnormal pop-up window, so as to search for a target processing instruction for processing the corresponding operation option in the processing instruction set, and after the target processing instruction is found, execute click or slide processing of the corresponding operation option according to the target processing instruction, and further close the first display interface (i.e., the abnormal pop-up window interface).
For example, fig. 5 is a schematic diagram of another alternative display interface processing method according to an embodiment of the present invention. As shown in fig. 5, when the application client a jumps out of the abnormal pop-up interface on the uppermost display interface of the terminal during the test process, "do the application client C start the microphone function, and allow? And if the target processing instruction indicates to click the 'permission' operation option, clicking the 'permission' operation option according to the target processing instruction, closing the abnormal popup box interface, and returning to the test interface of the application client A.
Fig. 6 is a schematic diagram of another alternative display interface processing method according to the embodiment of the present invention. As shown in fig. 6, when the application client a jumps out of the abnormal popup interface in the top display interface of the terminal during the test process of the application client a, "do the application client C update complete, and whether to restart the current device? And if the target processing instruction indicates not to restart the current equipment but to close the popup window to continue the test process of the application client A, the 'no' operation option is clicked according to the identified text. If the pop-up window is a malicious pop-up window, the operation option 'yes' really corresponds to not restarting the current equipment, and the pop-up window is closed, and the operation option 'no' corresponds to immediately restarting the current equipment, and the target processing instruction found only through text recognition is inaccurate. At this time, the background program corresponding to the current popup interface can be identified, the real processing operation corresponding to the operation option is identified, then the popup can be closed according to the instruction of the target processing instruction, the operation option of "yes" is correspondingly clicked, then the abnormal popup frame interface is closed, and the application client a returns to the test interface.
Optionally, after determining that the first display interface is the abnormal popup interface and is closed, the next interface that may jump does not return to the test interface of the application client, but jumps to another abnormal popup interface, and in this case, it is necessary to obtain the characteristic parameter of the uppermost display interface of the terminal again, determine whether the interface is the abnormal popup interface, and execute corresponding processing. Optionally, after the first display interface is closed and before a test interface for testing the application client is displayed on the uppermost layer of the terminal, the display interface processing method further includes:
s1, acquiring characteristic parameters of a second display interface displayed on the uppermost layer of the terminal;
s2, judging whether the second display interface is an abnormal popup interface according to the characteristic parameters of the second display interface;
and S3, closing the second display interface when the second display interface is judged to be the abnormal popup interface.
The feature parameters of the second display interface obtained here and the feature parameters of the first interface can be understood as the same type of feature parameters, including the transparency value of the second display interface and the area occupied by the second display interface on the terminal screen. And judging whether the second display interface is the abnormal popup interface according to the characteristic parameters of the second display interface, wherein the judgment mode of judging whether the first display interface is the abnormal popup interface according to the characteristic parameters of the first display interface is the same as that of judging whether the first display interface is the abnormal popup interface, and the judgment mode can be judged according to the transparency value of the second display interface and/or the occupied area of the second display interface on the terminal screen.
Optionally, the determining whether the second display interface is an abnormal pop-up interface according to the transparency value of the second display interface includes: judging whether the transparency value of the second display interface is greater than or equal to a third preset threshold value or not, and judging that the second display interface is an abnormal popup interface when the transparency value of the second display interface is greater than or equal to the third preset threshold value; when the transparency value of the second display interface is smaller than a third preset threshold, it can be determined that the second display interface is not an abnormal popup interface, and further determination can be performed by combining the area occupied by the second display interface on the screen of the terminal.
Optionally, the determining whether the second display interface is an abnormal pop-up interface according to the transparency value and an area occupied by the second display interface on the screen of the terminal includes: judging whether the area occupied by the second display interface on the screen of the terminal is smaller than or equal to a fourth preset threshold or not, and judging that the second display interface is an abnormal popup interface when the area occupied by the second display interface on the screen of the terminal is smaller than or equal to the fourth preset threshold; when the area of the second display interface on the screen of the terminal is larger than a fourth preset threshold, it can be determined that the second display interface is not an abnormal popup interface, and further determination can be performed by combining the transparency value of the second display interface.
Optionally, the determining whether the second display interface is an abnormal pop-up interface according to the transparency value and an area occupied by the second display interface on the screen of the terminal includes: when the transparency value of the second display interface is smaller than a third preset threshold and the area of the second display interface on the screen of the terminal is smaller than or equal to a fourth preset threshold, judging that the second display interface is an abnormal popup interface; when the transparency value of the second display interface is greater than or equal to a third preset threshold and the area of the second display interface on the screen of the terminal is greater than a second preset threshold, judging that the second display interface is an abnormal popup interface; and when the transparency value of the second display interface is greater than or equal to a third preset threshold value and the area of the second display interface on the screen of the terminal is less than or equal to a fourth preset threshold value, judging that the second display interface is an abnormal popup interface.
And closing the second display interface under the condition that the second display interface is judged to be the abnormal popup interface, wherein the closing of the second display interface can be realized through the following modes:
s1, identifying operation options in the second display interface, wherein the operation options comprise one or more options;
s2, searching a target processing instruction corresponding to a target option in the operation options in the stored processing instruction set, wherein the target processing instruction is used for indicating to close the second display interface;
and S3, closing the second display interface according to the target processing instruction.
For the method for identifying the operation option in the second display interface, reference may be made to the foregoing method for identifying the operation option in the first display interface. The operation instruction option identification here may be to identify a text and an image on the entire second display interface by analyzing the text and the image on the entire second display interface, record positions of the text and the image on the screen, determine a position of the corresponding operation option according to the identified positions of the text and the image, search a processing instruction set stored in the background for processing a target processing instruction of the corresponding operation option, after the target processing instruction is found, execute a click or slide process of the corresponding operation option according to the target processing instruction, and then close the second display interface (i.e., an abnormal pop-up window interface).
The operation instruction identifying option here may also be that the terminal identifies a background processing program corresponding to each operation option by identifying a background program corresponding to the current pop-up window interface, so as to know which operation option corresponds to the background program for closing the current abnormal pop-up window, so as to search for a target processing instruction for processing the corresponding operation option in the processing instruction set, and after the target processing instruction is found, execute click or slide processing of the corresponding operation option according to the target processing instruction, and further close the second display interface (i.e., the abnormal pop-up window interface).
It should be noted that, identifying the operation options in the second display interface mainly includes identifying operation instruction options, such as "yes", "no", "allow", "reject", "return", "open", "close", and the like, and also includes identifying a close button "x" of an abnormal pop-up window. The following describes an example of the processing manner when the second display interface is an abnormal popup interface with reference to fig. 7.
Fig. 7 is a schematic diagram of another alternative display interface processing method according to an embodiment of the present invention. As shown in fig. 7, when an abnormal pop-up interface (corresponding to a first display interface) jumps out from the topmost display interface of the terminal during the test of the application client a, "is the application client C updated and is the current device restarted? And if the target processing instruction indicates not to restart the current equipment but to close the popup window to continue the test process of the application client A, the 'no' operation option is clicked according to the identified text. And if the operation of the text display of the operation option is consistent with the operation actually executed by the background program, clicking 'No' according to the target processing instruction, and closing the abnormal popup window of the first display interface. After the abnormal popup of the first display interface is closed, the uppermost display interface of the terminal does not return to the test interface screen of the application client a but returns to the test interface of the application client a, but jumps to the next abnormal popup interface (equivalent to the second display interface) "do not determine to restart? And providing two operation options of yes and no, identifying the operation option of the abnormal popup of the second display interface again at the moment, finding a corresponding target processing instruction, and clicking a yes button according to the target processing instruction, so that the popup is closed without restarting the equipment.
Optionally, a close button "x" in the upper right corner of the abnormal pop-up interface may also be recognized, and the close button is clicked directly according to the instruction of the target processing instruction, so as to close the current pop-up interface. Or click the "back" option or the return key on the screen to close the current popup interface and return to the test interface.
Optionally, in the method for processing a display interface provided in the embodiment of the present invention, the obtaining of the characteristic parameter of the first display interface displayed on the uppermost layer of the terminal in step S202 may include, but is not limited to, the following implementation manners:
acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal at a specified moment;
acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal between two adjacent test operations, wherein the number of the test operations required to be executed in the process of testing the application client to be tested is multiple;
and acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal every other preset period.
Alternatively, the specified time may be any preset time, for example, the specified time is set to be 5 th, 15 th, 25 th, and 30 th times … … of the application client test, the characteristic parameters of the first display interface displayed on the uppermost layer of the terminal are acquired, when the test is performed to the corresponding time, the terminal automatically acquires the characteristic parameters of the uppermost display interface, and then performs recognition analysis to determine whether the uppermost display interface is an abnormal popup interface.
Alternatively, it can be understood that the test process includes a plurality of test operations to be performed, such as "jump action of test person", "fluency of test scene transition", and the like, or two adjacent click or slide operations, such as "open dialog box", "send message", and the like. Before the previous test operation is completed and the next test operation is started, the terminal can automatically acquire the characteristic parameters of the uppermost display interface, and then perform recognition analysis and judge whether the uppermost display interface is an abnormal popup interface.
Optionally, an obtaining period of the characteristic parameter may also be set, for example, the obtaining period of the characteristic parameter of the uppermost display interface is set to 10s, then in the test process of the application client, the terminal may automatically obtain the characteristic parameter of the uppermost display interface every 10s, and then perform recognition analysis and determine whether the uppermost display interface is an abnormal pop-up interface.
Optionally, in the process of executing the test, the application client may stop the current test process once the abnormal pop-up interface occurs, and stop the click or slide operation in the test, so that a background monitoring program may be set, and when it is monitored that the current test process is stopped, the characteristic parameter of the uppermost display interface is obtained, and whether the uppermost display interface is the abnormal pop-up interface is determined.
It should be noted that, for simplicity of description, the above-mentioned method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the order of acts, as some steps may occur in other orders or concurrently in accordance with the invention. Further, those skilled in the art should also appreciate that the embodiments described in the specification are preferred embodiments and that the acts and modules referred to are not necessarily required by the invention.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, or a network device) to execute the method according to the embodiments of the present invention.
Example 2
In this embodiment, a processing device for displaying an interface is further provided, and the device is used to implement the foregoing embodiments and preferred embodiments, and details of which have been already described are omitted. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated.
According to the embodiment of the invention, the processing device for implementing the display interface is also provided. Fig. 8 is a block diagram of a processing device for displaying an alternative interface according to an embodiment of the present invention. As shown in fig. 8, the apparatus includes:
an obtaining module 802, configured to obtain a characteristic parameter of a first display interface displayed on an uppermost layer of a terminal in a process of testing an application client to be tested on the terminal;
the judging module 804 is configured to judge whether the first display interface is an abnormal popup interface according to the characteristic parameter of the first display interface;
a closing module 806, configured to close the first display interface when it is determined that the first display interface is the abnormal pop-up interface;
the display module 808 is configured to display a test interface for testing the application client on the uppermost layer of the terminal.
By the device, the obtaining module 802 obtains the characteristic parameter of the first display interface displayed on the uppermost layer of the terminal in the process of testing the application client to be tested on the terminal, the judging module 804 judges whether the first display interface is an abnormal popup interface according to the characteristic parameter of the first display interface, the closing module 806 closes the first display interface under the condition that the first display interface is judged to be the abnormal popup interface, and the display module 808 displays the test interface for testing the application client on the uppermost layer of the terminal. Through the device, the problem that a large amount of closing operations need to be manually executed to close the abnormal popup window in the prior art is solved, so that a large amount of labor cost is saved, the abnormal popup window can be timely processed, the processing of the abnormal popup window is effectively avoided being omitted, and the success rate of the automatic test of the application client on the terminal is greatly improved.
Optionally, in the embodiment of the present invention, the processing method of the display interface may be applied to, but not limited to, different application clients, for example, a game application client, a shopping application client, a news application client, a video application client, a communication application client, a community space application client, and any other application client that can be installed on a terminal and tested.
Optionally, in an embodiment of the present invention, the first characteristic parameter may include, but is not limited to, at least one of: the transparency value of the first display interface and the area of the first display interface on the screen of the terminal.
It should be noted that the greater the transparency value, the greater the transparency, for example, when the transparency value is 100%, the description is completely transparent, when the transparency value is 0%, the description is opaque, and when the transparency value is 50%, the description is translucent. Generally, most of abnormal pop-ups are pop-ups with translucency or higher transparency, so that whether the abnormal pop-ups are abnormal can be judged according to the transparency value of the display interface. When the transparency of the pop-up window is low, the judgment can be further carried out by combining the occupied area of the display interface on the terminal screen. The abnormal pop-up window does not occupy the whole display screen generally, but is a small window interface, so that whether the abnormal pop-up window is the abnormal pop-up window can be judged according to the size of the display interface. For example, as shown in fig. 3, the test interface of the application client a occupies the size of the whole screen, and the abnormal popup interface during the test "is the application client C to start the microphone function, and is allowed? "show in the uppermost layer, would block ongoing testing. The abnormal popup interface can be displayed in the middle of the terminal screen, the size of the abnormal popup interface is less than one half of the whole terminal display screen, and the transparency can be set to be any value between 0% and 100%.
Fig. 9 is a block diagram of a processing device of an alternative display interface according to an embodiment of the present invention. As shown in fig. 9, optionally, the determining module 804 includes a determining unit 902 for:
judging whether the first display interface is an abnormal popup interface or not according to the transparency value of the first display interface; judging whether the first display interface is an abnormal popup interface or not according to the area occupied by the first display interface on the screen of the terminal; and judging whether the first display interface is an abnormal popup interface or not according to the transparency value and the area of the first display interface on the screen of the terminal.
The determining unit 902 may further include a determining subunit 9020, configured to:
judging whether the transparency value of the first display interface is greater than or equal to a first preset threshold value or not, and judging that the first display interface is an abnormal popup interface when the transparency value of the first display interface is greater than or equal to the first preset threshold value; when the transparency value of the first display interface is smaller than a first preset threshold value, judging that the first display interface is not an abnormal popup interface, and performing further judgment by combining the area occupied by the first display interface on the screen of the terminal;
judging whether the area occupied by the first display interface on the screen of the terminal is smaller than or equal to a second preset threshold or not, and judging that the first display interface is an abnormal popup interface when the area occupied by the first display interface on the screen of the terminal is smaller than or equal to the second preset threshold; when the area of the first display interface on the screen of the terminal is larger than a second preset threshold, judging that the first display interface is not an abnormal popup interface, and performing further judgment by combining the transparency value of the first display interface;
when the transparency value of the first display interface is smaller than a first preset threshold value and the area of the first display interface on the screen of the terminal is smaller than or equal to a second preset threshold value, judging that the first display interface is an abnormal popup interface; when the transparency value of the first display interface is larger than or equal to a first preset threshold value and the area of the first display interface on the screen of the terminal is larger than a second preset threshold value, judging that the first display interface is an abnormal popup interface; and when the transparency value of the first display interface is greater than or equal to a first preset threshold value and the area of the first display interface on the screen of the terminal is less than or equal to a second preset threshold value, judging that the first display interface is an abnormal popup interface.
It should be noted that, the first preset threshold and the second preset threshold may be flexibly set according to a technical level that can be achieved in the related art, which is not limited in the embodiment of the present invention.
Optionally, the shutdown module 806 includes:
an identifying unit 904, configured to identify an operation option in the first display interface, where the operation option includes one or more options;
a searching unit 906, configured to search, in the stored processing instruction set, a target processing instruction corresponding to a target option in the operation options, where the target processing instruction is used to instruct to close the first display interface;
a closing unit 908, configured to close the first display interface according to the target processing instruction.
It should be noted that, identifying the operation options in the first display interface mainly includes identifying operation instruction options, such as "yes", "no", "allow", "reject", "return", "open", "close", and the like, and also includes identifying a close button "x" of an abnormal pop-up window.
The operation option identification here may be to identify a text and an image on the entire first display interface by parsing the text and the image, record positions of the text and the image on the screen, determine a position of the corresponding operation option according to the identified positions of the text and the image, search a processing instruction set stored in the background for processing a target processing instruction of the corresponding operation option, and after the target processing instruction is found, execute a click or slide process of the corresponding operation option according to the target processing instruction, thereby closing the first display interface (i.e., the abnormal pop-up window interface). As shown in fig. 4, the current interface may include click operation options "allow" and "deny" and may also include slide operation options, such as "slide bar to right close" below.
The operation option identification step may also be that the terminal identifies a background processing program corresponding to each operation option by identifying a background program corresponding to the current pop-up window interface, so as to know which operation option corresponds to the background program for closing the current abnormal pop-up window, so as to search for a target processing instruction for processing the corresponding operation option in the processing instruction set, and after the target processing instruction is found, execute click or slide processing of the corresponding operation option according to the target processing instruction, and further close the first display interface (i.e., the abnormal pop-up window interface).
For example, as shown in fig. 5, when an abnormal pop-up interface jumps out from the uppermost display interface of the terminal during the test of the application client a, "do the application client C want to start the microphone function, and allow? And if the target processing instruction indicates to click the 'permission' operation option, clicking the 'permission' operation option according to the target processing instruction, closing the abnormal popup box interface, and returning to the test interface of the application client A.
As shown in fig. 6, when the application client a jumps out of the abnormal popup interface in the top display interface of the terminal during the test process of the application client a, "do the application client C update complete, and whether to restart the current device? And if the target processing instruction indicates not to restart the current equipment but to close the popup window to continue the test process of the application client A, the 'no' operation option is clicked according to the identified text. If the pop-up window is a malicious pop-up window, the operation option 'yes' really corresponds to not restarting the current equipment, and the pop-up window is closed, and the operation option 'no' corresponds to immediately restarting the current equipment, and the target processing instruction found only through text recognition is inaccurate. At this time, the background program corresponding to the current popup interface can be identified, the real processing operation corresponding to the operation option is identified, then the popup can be closed according to the instruction of the target processing instruction, the operation option of "yes" is correspondingly clicked, then the abnormal popup frame interface is closed, and the application client a returns to the test interface.
Optionally, after determining that the first display interface is the abnormal popup interface and is closed, the next interface that may jump does not return to the test interface of the application client, but jumps to another abnormal popup interface, and in this case, it is necessary to obtain the characteristic parameter of the uppermost display interface of the terminal again, determine whether the interface is the abnormal popup interface, and execute corresponding processing.
Optionally, the obtaining module 802 is further configured to: acquiring characteristic parameters of a second display interface displayed on the uppermost layer of the terminal;
the determining module 804 is further configured to: judging whether the second display interface is an abnormal popup interface or not according to the characteristic parameters of the second display interface;
the shutdown module 806 is further configured to: and closing the second display interface under the condition that the second display interface is judged to be the abnormal popup interface.
The feature parameters of the second display interface obtained here and the feature parameters of the first interface can be understood as the same type of feature parameters, including the transparency value of the second display interface and the area occupied by the second display interface on the terminal screen. And judging whether the second display interface is the abnormal popup interface according to the characteristic parameters of the second display interface in the same manner as the judgment of whether the first display interface is the abnormal popup interface according to the characteristic parameters of the first display interface, wherein the judgment can be carried out according to the transparency value of the second display interface and/or the occupied area of the second display interface on the terminal screen, and the details are not repeated here. And closing the second display interface under the condition that the second display interface is judged to be the abnormal popup interface, wherein the closing of the second display interface can be realized through the following modes:
s1, identifying operation options in the second display interface, wherein the operation options comprise one or more options;
s2, searching a target processing instruction corresponding to a target option in the operation options in the stored processing instruction set, wherein the target processing instruction is used for indicating to close the second display interface;
and S3, closing the second display interface according to the target processing instruction.
The operation instruction option identification here may be to identify a text and an image on the entire second display interface by analyzing the text and the image on the entire second display interface, record positions of the text and the image on the screen, determine a position of the corresponding operation option according to the identified positions of the text and the image, search a processing instruction set stored in the background for processing a target processing instruction of the corresponding operation option, after the target processing instruction is found, execute a click or slide process of the corresponding operation option according to the target processing instruction, and then close the second display interface (i.e., an abnormal pop-up window interface).
The operation instruction identifying option here may also be that the terminal identifies a background processing program corresponding to each operation option by identifying a background program corresponding to the current pop-up window interface, so as to know which operation option corresponds to the background program for closing the current abnormal pop-up window, so as to search for a target processing instruction for processing the corresponding operation option in the processing instruction set, and after the target processing instruction is found, execute click or slide processing of the corresponding operation option according to the target processing instruction, and further close the second display interface (i.e., the abnormal pop-up window interface).
For the method for identifying the operation option in the second display interface, reference may be made to the foregoing method for identifying the operation option in the first display interface.
It should be noted that, identifying the operation options in the second display interface mainly includes identifying operation instruction options, such as "yes", "no", "allow", "reject", "return", "open", "close", and the like, and also includes identifying a close button "x" of an abnormal pop-up window. The following describes an example of the processing manner when the second display interface is an abnormal popup interface with reference to fig. 7.
As shown in fig. 7, when an abnormal pop-up interface (corresponding to a first display interface) jumps out from the topmost display interface of the terminal during the test of the application client a, "is the application client C updated and is the current device restarted? And if the target processing instruction indicates not to restart the current equipment but to close the popup window to continue the test process of the application client A, the 'no' operation option is clicked according to the identified text. And if the operation of the text display of the operation option is consistent with the operation actually executed by the background program, clicking 'No' according to the target processing instruction, and closing the abnormal popup window of the first display interface. After the abnormal popup of the first display interface is closed, the uppermost display interface of the terminal does not return to the test interface screen of the application client a but returns to the test interface of the application client a, but jumps to the next abnormal popup interface (equivalent to the second display interface) "do not determine to restart? And providing two operation options of yes and no, identifying the operation option of the abnormal popup of the second display interface again at the moment, finding a corresponding target processing instruction, and clicking a yes button according to the target processing instruction, so that the popup is closed without restarting the equipment.
Optionally, a close button "x" in the upper right corner of the abnormal pop-up interface may also be recognized, and the close button is clicked directly according to the instruction of the target processing instruction, so as to close the current pop-up interface. Or click the "back" option or the return key on the screen to close the current popup interface and return to the test interface.
Optionally, the obtaining module 802 may further include:
an obtaining unit 910, configured to obtain, at a specified time, a characteristic parameter of a first display interface displayed on an uppermost layer of a terminal; acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal between two adjacent test operations, wherein the number of the test operations required to be executed in the process of testing the application client to be tested is multiple; and acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal every other preset period.
Alternatively, the specified time may be any preset time, for example, the specified time is set to be 5 th, 15 th, 25 th, and 30 th times … … of the application client test, the characteristic parameters of the first display interface displayed on the uppermost layer of the terminal are acquired, when the test is performed to the corresponding time, the terminal automatically acquires the characteristic parameters of the uppermost display interface, and then performs recognition analysis to determine whether the uppermost display interface is an abnormal popup interface.
Alternatively, it can be understood that the test process includes a plurality of test operations to be performed, such as "jump action of test person", "fluency of test scene transition", and the like, or two adjacent click or slide operations, such as "open dialog box", "send message", and the like. Before the previous test operation is completed and the next test operation is started, the terminal can automatically acquire the characteristic parameters of the uppermost display interface, and then perform recognition analysis and judge whether the uppermost display interface is an abnormal popup interface.
Optionally, an obtaining period of the characteristic parameter may also be set, for example, the obtaining period of the characteristic parameter of the uppermost display interface is set to 10s, then in the test process of the application client, the terminal may automatically obtain the characteristic parameter of the uppermost display interface every 10s, and then perform recognition analysis and determine whether the uppermost display interface is an abnormal pop-up interface.
Optionally, in the process of executing the test, the application client may stop the current test process once the abnormal pop-up interface occurs, and stop the click or slide operation in the test, so that a background monitoring program may be set, and when it is monitored that the current test process is stopped, the characteristic parameter of the uppermost display interface is obtained, and whether the uppermost display interface is the abnormal pop-up interface is determined.
Example 3
The application environment of the embodiment of the present invention may refer to the application environment in embodiment 1, but is not described herein again.
Optionally, in this embodiment, the processing method of the display interface may be embodied by the following implementation manners, including:
s1, in the automatic test, real-time monitoring whether a pop-up box (equivalent to the abnormal pop-up window interface) exists;
s1.1, injecting an automatic script into a client, jumping an APP (equivalent to the application client) page, and updating a view layer (equivalent to the uppermost display interface of the terminal);
s1.2, detecting and triggering a pop-up box, and extracting a display picture of the current view layer (which is equivalent to acquiring characteristic parameters of a first display interface);
s1.3, calculating the percentage of the displayed picture to the screen size, and when the percentage is smaller than a preset value, obtaining that the displayed picture of the layer of view is a pop-up frame, or judging the transparency of the pop-up frame, and if the transparency is larger than the preset value, obtaining that the displayed picture of the layer of view is the pop-up frame;
s2, pop-up frame processing:
s2.1, a single or a plurality of confirmation buttons exist in the pop-up box, such as confirmation, cancellation, permission and the like;
s2.2, presetting a click confirmation button or a close button or a Back button in the script, and closing the pop-up box;
and S2.3, after the page is refreshed, detecting the picture displayed by the view layer again, calculating the transparency of the pop-up frame or the percentage of the displayed picture to the size of the screen, and starting circularly.
A specific embodiment of the method for determining whether the display interface is an abnormal popup interface and processing the interface according to the transparency of the display interface will be described below with reference to fig. 10. Fig. 10 is a flowchart of a further alternative processing method for a display interface according to an embodiment of the present invention, and as shown in fig. 10, the processing method for a display interface includes:
s1002, in the automatic testing process of the application client, when the next testing operation is executed, the matched control needs to be identified for clicking or sliding. For example, in the application client C running a test, if the dialog function is to be tested, taking the dialog with a as an example, a control (shown as the avatar of a) for opening the dialog needs to be found and clicked, and then the dialog interface is entered.
And S1004, judging whether a matched control is found, if so, executing the step S1006, and if not, executing the step S1010.
And S1006, after finding the matched control, clicking or sliding to enter a next test interface. For example, an avatar for A is found and double-clicking on the avatar enters the dialog interface with A.
And S1008, executing the next automatic operation. For example, after entering the dialog interface with a, if it is desired to continue to test whether the message transmission is successful or the display condition of the emotion transmission, the control matched with the next test may be continuously searched.
And S1010, if the control matched with the test is not found, executing the identification processing of the abnormal popup window, and detecting the transparency of the uppermost view layer. For example, if the avatar of a is not found, the terminal will check the top view transparency to see if the avatar option of a is covered by a mask (corresponding to an abnormal pop-up interface).
S1012, after the transparency of the top view layer is obtained, determining whether the transparency value exceeds a preset threshold, if so, determining that the top view layer is an abnormal popup interface, and executing S1014.
S1014, starting an abnormal popup window matching processing flow. For example, if it is determined in step S1012 that the avatar of a is covered by the mask, the mask is closed, the avatar of a is displayed, and a click operation may be performed. At this time, the abnormal popup matching process may be the same as the previous control matching processes S1002 to S1008. Analyzing and identifying the current abnormal popup interface, searching a control corresponding to the closed abnormal popup interface, clicking or sliding the corresponding control after finding the control, closing the abnormal popup interface, and then executing the next step of automatic operation, for example, returning to a test interface before the abnormal popup, searching the head portrait of the A and clicking.
The above-mentioned flow is circularly executed.
In step S1010, the size of the area occupied by the top view layer on the screen, or the transparency of the top view layer and the size of the area occupied by the top view layer on the screen may be identified, and whether the pop-up interface is an abnormal pop-up interface may be determined according to the determination method listed in embodiment 1.
Example 4
The embodiment of the invention also provides a storage medium. Optionally, in this embodiment, the storage medium may be located in at least one of a plurality of network devices in a network.
Optionally, in this embodiment, the storage medium is configured to store program code for performing the following steps:
s1, acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal in the process of testing the application client to be tested on the terminal;
s2, judging whether the first display interface is an abnormal popup interface according to the characteristic parameters of the first display interface;
and S3, closing the first display interface and displaying a test interface for testing the application client on the uppermost layer of the terminal under the condition that the first display interface is judged to be the abnormal popup interface.
Optionally, the storage medium is further arranged to store program code for performing the steps of:
and S1, judging whether the first display interface is an abnormal popup interface or not according to the transparency value of the first display interface or according to the transparency value and the area of the first display interface on the screen of the terminal.
Optionally, in this embodiment, the storage medium may include, but is not limited to: a U-disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic or optical disk, and other various media capable of storing program codes.
Optionally, the specific examples in this embodiment may refer to the examples described in embodiment 1 and embodiment 2, and this embodiment is not described herein again.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
The integrated unit in the above embodiments, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in the above computer-readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for causing one or more computer devices (which may be personal computers, servers, network devices, etc.) to execute all or part of the steps of the method according to the embodiments of the present invention.
In the above embodiments of the present invention, the descriptions of the respective embodiments have respective emphasis, and for parts that are not described in detail in a certain embodiment, reference may be made to related descriptions of other embodiments.
In the several embodiments provided in the present application, it should be understood that the disclosed client may be implemented in other manners. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one type of division of logical functions, and there may be other divisions when actually implemented, for example, a plurality of units or components may be combined or may be integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, units or modules, and may be in an electrical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The foregoing is only a preferred embodiment of the present invention, and it should be noted that, for those skilled in the art, various modifications and decorations can be made without departing from the principle of the present invention, and these modifications and decorations should also be regarded as the protection scope of the present invention.
Claims (10)
1. A processing method for a display interface is characterized by comprising the following steps:
the method comprises the steps that in the process of testing an application client to be tested on a terminal, characteristic parameters of a first display interface displayed on the uppermost layer of the terminal are obtained;
judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface;
under the condition that the first display interface is judged to be the abnormal popup interface, closing the first display interface, and displaying a test interface for testing the application client at the uppermost layer of the terminal; wherein closing the first display interface comprises: identifying characters and graphs by analyzing texts and images on the whole first display interface, and recording positions of the characters and the graphs on a screen; determining the position of the corresponding operation option according to the identified positions of the characters and the graphics; searching a target processing instruction for processing the operation option in a processing instruction set stored in a background; identifying a background processing program corresponding to each operation option by identifying the background program corresponding to the first display interface so as to determine the operation option of the background program for closing the first display interface, and after finding the target processing instruction, executing corresponding click or sliding processing of the operation option for closing the background program for the first display interface according to the target processing instruction so as to close the first display interface;
after the first display interface is closed and before a test interface for testing an application client is displayed on the uppermost layer of the terminal, acquiring characteristic parameters of a second display interface displayed on the uppermost layer of the terminal;
judging whether the second display interface is an abnormal popup interface or not according to the characteristic parameters of the second display interface;
under the condition that the second display interface is judged to be the abnormal popup interface, identifying a background processing program corresponding to each operation option by identifying the background program corresponding to the second display interface so as to determine the operation option of the background program for closing the second display interface, searching a target processing instruction for processing the corresponding operation option in a processing instruction set, and after the target processing instruction is found, executing click or sliding processing of the corresponding operation option for closing the background program of the second display interface according to the target processing instruction so as to close the second display interface;
the judging whether the first display interface is an abnormal popup interface according to the characteristic parameters of the first display interface comprises the following steps:
and judging whether the first display interface is an abnormal popup interface or not according to the transparency value of the first display interface or the transparency value of the first display interface and the area occupied by the first display interface on the screen of the terminal.
2. The method of claim 1, wherein the determining whether the first display interface is an abnormal pop-up interface according to the transparency value of the first display interface comprises:
judging whether the transparency value of the first display interface is larger than or equal to a first preset threshold value or not;
and when the transparency value of the first display interface is greater than or equal to the first preset threshold value, judging that the first display interface is an abnormal popup interface.
3. The method according to claim 1, wherein the determining whether the first display interface is an abnormal popup interface according to the transparency value of the first display interface or according to the transparency value and an area occupied by the first display interface on the screen of the terminal comprises:
judging whether the transparency value of the first display interface is larger than or equal to a first preset threshold value or not and whether the area of the first display interface on the screen of the terminal is smaller than or equal to a second preset threshold value or not;
and when the transparency value of the first display interface is smaller than the first preset threshold value and the area of the first display interface on the screen of the terminal is smaller than or equal to the second preset threshold value, judging that the first display interface is an abnormal popup interface.
4. The method of claim 1, wherein closing the first display interface comprises:
identifying operation options in the first display interface, wherein the operation options comprise one or more options;
searching a target processing instruction corresponding to a target option in the operation options in a stored processing instruction set, wherein the target processing instruction is used for indicating to close the first display interface;
and closing the first display interface according to the target processing instruction.
5. The method according to claim 1, wherein the obtaining of the characteristic parameter of the first display interface displayed at the uppermost layer of the terminal comprises at least one of:
acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal at a specified moment;
acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal between two adjacent test operations, wherein the number of the test operations required to be executed in the process of testing the application client to be tested is multiple;
and acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal every other preset period.
6. A processing apparatus for displaying an interface, comprising:
the system comprises an acquisition module, a display module and a display module, wherein the acquisition module is used for acquiring characteristic parameters of a first display interface displayed on the uppermost layer of a terminal in the process of testing an application client to be tested on the terminal;
the judging module is used for judging whether the first display interface is an abnormal popup interface or not according to the characteristic parameters of the first display interface;
the closing module is used for closing the first display interface under the condition that the first display interface is judged to be the abnormal popup interface;
the display module is used for displaying a test interface for testing the application client on the uppermost layer of the terminal;
the closing module is used for closing the first display interface in the following mode:
identifying characters and graphs by analyzing texts and images on the whole first display interface, and recording positions of the characters and the graphs on a screen; determining the position of the corresponding operation option according to the identified positions of the characters and the graphics; searching a target processing instruction for processing the operation option in a processing instruction set stored in a background; identifying a background processing program corresponding to each operation option by identifying the background program corresponding to the first display interface so as to determine the operation option of the background program for closing the first display interface, and after finding the target processing instruction, executing corresponding click or sliding processing of the operation option for closing the background program for the first display interface according to the target processing instruction so as to close the first display interface;
the acquisition module is further configured to: after the first display interface is closed and before a test interface for testing an application client is displayed on the uppermost layer of the terminal, acquiring characteristic parameters of a second display interface displayed on the uppermost layer of the terminal;
the judging module is further configured to: judging whether the second display interface is an abnormal popup interface or not according to the characteristic parameters of the second display interface;
the shutdown module is further to: closing the second display interface under the condition that the second display interface is judged to be the abnormal popup interface;
the judging module comprises:
and the judging unit is used for judging whether the first display interface is an abnormal popup interface or not according to the transparency value of the first display interface or according to the transparency value and the area occupied by the first display interface on the screen of the terminal.
7. The apparatus according to claim 6, wherein the judging unit includes:
the judging subunit is used for judging whether the transparency value of the first display interface is greater than or equal to a first preset threshold value; and when the transparency value of the first display interface is greater than or equal to the first preset threshold value, judging that the first display interface is an abnormal popup interface.
8. The apparatus according to claim 6, wherein the judging unit includes:
the judging subunit is configured to judge whether the transparency value of the first display interface is greater than or equal to a first preset threshold, and whether an area occupied by the first display interface on the screen of the terminal is less than or equal to a second preset threshold; and when the transparency value of the first display interface is greater than or equal to the first preset threshold value and the area of the first display interface on the screen of the terminal is less than or equal to the second preset threshold value, judging that the first display interface is an abnormal popup interface.
9. The apparatus of claim 6, wherein the shutdown module comprises:
the identification unit is used for identifying operation options in the first display interface, wherein the operation options comprise one or more options;
the searching unit is used for searching a target processing instruction corresponding to a target option in the operation options in a stored processing instruction set, wherein the target processing instruction is used for indicating to close the first display interface;
and the closing unit is used for closing the first display interface according to the target processing instruction.
10. The apparatus of claim 6, wherein the obtaining module comprises:
the acquisition unit is used for acquiring the characteristic parameters of a first display interface displayed on the uppermost layer of the terminal at a specified moment; acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal between two adjacent test operations, wherein the number of the test operations required to be executed in the process of testing the application client to be tested is multiple; and acquiring characteristic parameters of a first display interface displayed on the uppermost layer of the terminal every other preset period.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710081534.5A CN108427633B (en) | 2017-02-15 | 2017-02-15 | Display interface processing method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710081534.5A CN108427633B (en) | 2017-02-15 | 2017-02-15 | Display interface processing method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108427633A CN108427633A (en) | 2018-08-21 |
CN108427633B true CN108427633B (en) | 2021-08-06 |
Family
ID=63155398
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710081534.5A Active CN108427633B (en) | 2017-02-15 | 2017-02-15 | Display interface processing method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108427633B (en) |
Families Citing this family (16)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110795333A (en) * | 2018-11-07 | 2020-02-14 | 北京安天网络安全技术有限公司 | Method, device and storage equipment for enabling program to run uninterruptedly |
CN110032510B (en) * | 2019-03-07 | 2022-05-20 | 深圳市腾讯信息技术有限公司 | Application testing method and device |
CN111767203A (en) * | 2019-04-01 | 2020-10-13 | 北京奇虎科技有限公司 | Application test-based bullet frame processing method and system |
CN110457214B (en) * | 2019-07-30 | 2023-10-13 | 腾讯科技(深圳)有限公司 | Application testing method and device and electronic equipment |
CN110751013B (en) * | 2019-08-19 | 2024-08-20 | 腾讯科技(深圳)有限公司 | Scene recognition method, apparatus and computer readable storage medium |
CN110580221A (en) * | 2019-08-21 | 2019-12-17 | 东软集团股份有限公司 | Control testing method and device, storage medium and electronic equipment |
CN110851299A (en) * | 2019-11-15 | 2020-02-28 | 深圳前海微众银行股份有限公司 | Automatic flow exception eliminating method, device, equipment and storage medium |
CN111125433A (en) * | 2019-12-13 | 2020-05-08 | 珠海格力电器股份有限公司 | Popup window management method and device, electronic equipment and readable storage medium |
CN113536870A (en) * | 2020-07-09 | 2021-10-22 | 腾讯科技(深圳)有限公司 | Abnormal head portrait identification method and device |
CN111966562B (en) * | 2020-07-21 | 2024-07-02 | 北京视博云信息技术有限公司 | Cloud platform monitoring method and device and readable storage medium |
CN112099885A (en) * | 2020-08-17 | 2020-12-18 | 联想(北京)有限公司 | Popup window processing method and device, equipment and storage medium |
CN112073579B (en) * | 2020-08-27 | 2022-06-10 | 北京指掌易科技有限公司 | Terminal operation playback processing method and device, terminal equipment and storage medium |
CN112988568B (en) * | 2021-02-04 | 2024-05-28 | 上海硬通网络科技有限公司 | Game testing method and device and electronic equipment |
CN113900750B (en) * | 2021-09-26 | 2024-02-23 | 珠海豹好玩科技有限公司 | Method and device for determining window interface boundary, storage medium and electronic equipment |
CN115185789A (en) * | 2022-09-08 | 2022-10-14 | 深圳数鉴科技有限公司 | Popup data analysis method and system |
CN117149340B (en) * | 2023-10-30 | 2024-02-06 | 北京小米移动软件有限公司 | USIM card application interface display method and device and electronic equipment |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104516812A (en) * | 2013-09-27 | 2015-04-15 | 腾讯科技(深圳)有限公司 | Method and device for testing software |
CN105183643A (en) * | 2015-08-18 | 2015-12-23 | 惠州Tcl移动通信有限公司 | Automatic testing interference preventing method and apparatus for Android mobile terminal |
Family Cites Families (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7278114B2 (en) * | 2002-12-30 | 2007-10-02 | Viewspace Technologies | Method and apparatus for managing display of popup windows |
CN102819713B (en) * | 2012-06-29 | 2015-09-16 | 北京奇虎科技有限公司 | A kind of method and system detecting bullet window safe |
CN103914387B (en) * | 2014-04-23 | 2016-08-17 | 广东欧珀移动通信有限公司 | The method and apparatus getting rid of abnormal interference in Android phone automatic test course |
CN105786687B (en) * | 2014-12-22 | 2019-01-08 | 博雅网络游戏开发(深圳)有限公司 | Mobile application test method and device |
CN105320542B (en) * | 2015-11-04 | 2018-09-14 | 上海聚力传媒技术有限公司 | A kind of method and apparatus that mobile terminal exits abnormal interface |
-
2017
- 2017-02-15 CN CN201710081534.5A patent/CN108427633B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104516812A (en) * | 2013-09-27 | 2015-04-15 | 腾讯科技(深圳)有限公司 | Method and device for testing software |
CN105183643A (en) * | 2015-08-18 | 2015-12-23 | 惠州Tcl移动通信有限公司 | Automatic testing interference preventing method and apparatus for Android mobile terminal |
Also Published As
Publication number | Publication date |
---|---|
CN108427633A (en) | 2018-08-21 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108427633B (en) | Display interface processing method and device | |
US10554805B2 (en) | Information processing method, terminal, and computer-readable storage medium | |
CN108804299B (en) | Application program exception handling method and device | |
CN111641677B (en) | Message reminding method, message reminding device and electronic equipment | |
CN105471935B (en) | Information prompting method and device | |
CN107329659B (en) | Permission setting method and device, electronic equipment and storage medium | |
CN111552633A (en) | Interface abnormal call testing method and device, computer equipment and storage medium | |
CN109194689B (en) | Abnormal behavior recognition method, device, server and storage medium | |
CN107704233B (en) | Information processing method and electronic equipment | |
CN109271228A (en) | Interface function recognition methods, device and the electronic equipment of application | |
CN110490101A (en) | A kind of picture intercept method, device and computer storage medium | |
CN114205212A (en) | Network security early warning method, device, equipment and readable storage medium | |
CN112148606A (en) | Embedded point testing method, device, equipment and computer readable medium | |
CN109598120A (en) | Security postures intelligent analysis method, device and the storage medium of mobile terminal | |
CN112307464A (en) | Fraud identification method and device and electronic equipment | |
CN106874718B (en) | Privacy processing method and device and terminal | |
CN105574410B (en) | Application program safety detection method and device | |
CN110442499A (en) | Test, the method and apparatus for improving page response performance, terminal device | |
CN111782514B (en) | Test data comparison method and device | |
CN111093046B (en) | Display screen opening method based on image acquisition equipment and terminal equipment | |
CN109254820B (en) | Window closing method, device, terminal and computer readable storage medium | |
CN104571812B (en) | Information processing method and electronic equipment | |
CN111611470A (en) | Data processing method and device and electronic equipment | |
CN108932148A (en) | Pop-up management method and device | |
CN110659082A (en) | Application program interface display method and device, terminal and storage medium |
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 |