CN112306892B - Page response duration testing method and related equipment - Google Patents

Page response duration testing method and related equipment Download PDF

Info

Publication number
CN112306892B
CN112306892B CN202011348490.6A CN202011348490A CN112306892B CN 112306892 B CN112306892 B CN 112306892B CN 202011348490 A CN202011348490 A CN 202011348490A CN 112306892 B CN112306892 B CN 112306892B
Authority
CN
China
Prior art keywords
page
target
video
cutting
tested
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
Application number
CN202011348490.6A
Other languages
Chinese (zh)
Other versions
CN112306892A (en
Inventor
孙春旭
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Fangduoduo Network Technology Co ltd
Original Assignee
Shenzhen Fangduoduo Network Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Fangduoduo Network Technology Co ltd filed Critical Shenzhen Fangduoduo Network Technology Co ltd
Priority to CN202011348490.6A priority Critical patent/CN112306892B/en
Publication of CN112306892A publication Critical patent/CN112306892A/en
Application granted granted Critical
Publication of CN112306892B publication Critical patent/CN112306892B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/3668Software testing
    • G06F11/3672Test management
    • G06F11/3688Test management for test execution, e.g. scheduling of test suites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04845Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Human Computer Interaction (AREA)
  • Television Signal Processing For Recording (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The embodiment of the invention provides a method and related equipment for testing page response time length, which can improve the testing precision of the page response time length. The method comprises the following steps: acquiring a target video corresponding to a target application program; determining a first clipping time interval of a target page according to the duration of a target video; cutting the target video based on a first cutting time interval corresponding to the target page to obtain a first picture set corresponding to the target video; determining a first video starting page and a first video ending page; determining a second clipping time interval according to the first video end page name and the first video start page name; cutting the target video from the initial cutting moment according to a second cutting time interval until the cutting moment is finished to obtain a second picture set; determining a target starting page most similar to the starting page to be tested, and determining a target ending page most similar to the ending page to be tested; and determining the response time length according to the target ending page and the target starting page.

Description

Page response duration testing method and related equipment
Technical Field
The present invention relates to the field of communications, and in particular, to a method for testing page response duration and related devices.
Background
With the development of science and technology, Applications (APPs) have been developed, and in the actual development process, after the APP development is completed, the performance of the APP needs to be tested.
When testing the performance of APP, can pay close attention to the response duration of APP page, the mode that obtains the response duration can pass through the mode of third party application, but can not record the response time of opening APP sometimes through the third party application, and the difference of the data of obtaining moreover and user's operation on the sense organ is great, and then leads to the troublesome poeration, and the accuracy is not high.
For an application system, the response time of a page is generally determined according to a video corresponding to the page operation. In the existing scheme, the clipping time interval is generally set according to human experience, however, if the time interval is set to be too small, the accuracy of the response time length can be improved, but the processing efficiency is influenced greatly. If too large a time interval is set, the test accuracy is affected. After the time interval is determined, the work efficiency is only related to the video duration. However, since the start frame and the end frame of the video are not necessarily the start page and the end page to be tested, if the cropping is performed at a certain fixed time interval, the work efficiency is affected.
Disclosure of Invention
The embodiment of the invention provides a method and related equipment for testing page response time length, which can provide the test precision of the page response time length.
A first aspect of an embodiment of the present invention provides a method for testing a page response duration, where the method includes:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video;
analyzing the target video to obtain a frame rate of the target video, and determining the duration of the target video according to the frame rate;
determining a first clipping time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
cutting the target video based on a first cutting time interval corresponding to the target page to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
determining the first video starting page and the first video ending page from the first picture set according to a starting page to be tested and an ending page to be tested; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
determining a second clipping time interval of the target video, the initial clipping time of the target video and the end clipping time according to the name of a first video end page and the name of a first video start page; the second clipping time interval is smaller than the first clipping time interval;
cutting the target video from the initial cutting time according to the second cutting time interval until the cutting of the target video is finished at the cutting finishing time to obtain a second picture set, wherein the second picture set comprises a plurality of second cutting pages which are sequenced according to a cutting time sequence, and the names of the second cutting pages are named according to the second cutting time interval and the corresponding cutting times;
determining a second cutting page which is most similar to the starting page to be tested in the second picture set as a target starting page, and determining a second cutting page which is most similar to the ending page to be tested in the second picture set as a target ending page;
and determining the response time length according to the name of the target ending page and the name of the target starting page.
In an optional manner, the target video is cropped based on a first cropping time interval corresponding to the target page, so as to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and comprise:
cutting the target video from a first frame image of the target video to a last frame image of the target video by taking the first cutting time interval as a reference;
when the residual length of the target video is smaller than the cutting time interval, determining a video frame corresponding to the residual length of the target video;
and determining the last picture of the first picture set according to the video frame corresponding to the residual length of the target video.
In an optional mode, determining a second clipping time interval of the target video, an initial clipping time of the target video and an end clipping time according to a name of a first video end page and a name of a first video start page; the second cropping interval is smaller than the first cropping interval, including:
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment;
determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time;
subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration;
and determining a second cutting time interval according to the target duration.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page;
performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the first similar page with the highest similarity of the target area as the first cutting page most similar to the starting page to be tested.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page;
performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the second similar page with the highest similarity of the target area as the first cutting page most similar to the to-be-tested end page.
In an optional manner, acquiring a target video corresponding to a target application program, a start page to be tested and an end page to be tested corresponding to the target video includes:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video from a target folder path;
the target video is cut based on a first cutting time interval corresponding to the target page, so that a first picture set corresponding to the target video is obtained; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and the names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and the method comprises the following steps:
and storing the first picture set into the target folder according to the cutting time sequence.
A second aspect of the embodiments of the present invention provides a device for testing a page response duration, including:
the system comprises a first acquisition module, a second acquisition module and a third acquisition module, wherein the first acquisition module is used for acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video;
the analysis module is used for analyzing the target video to obtain the frame rate of the target video and determining the duration of the target video according to the frame rate;
the first determining module is used for determining a first cutting time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
the first cutting module is used for cutting the target video based on a first cutting time interval corresponding to the target page so as to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
the first output page is used for determining the first video starting page and the first video ending page from the first picture set according to a starting page to be tested and an ending page to be tested; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
a second determining module, configured to determine, according to a name of a first video end page and a name of the first video start page, a second clipping time interval for the target video, an initial clipping time of the target video, and an end clipping time; the second clipping time interval is smaller than the first clipping time interval;
the second clipping module is used for clipping the target video from the initial clipping moment according to the second clipping time interval until the clipping of the target video is finished at the clipping finishing moment to obtain a second picture set, wherein the second picture set comprises a plurality of second clipping pages which are sequenced according to the clipping time sequence, and the names of the second clipping pages are named according to the second clipping time interval and the corresponding clipping times;
a third determining module, configured to determine that a second clipping page, which is most similar to the start page to be tested, in the second picture set is a target start page, and determine that a second clipping page, which is most similar to the end page to be tested, in the second picture set is a target end page;
and the response time length determining module is used for determining the response time length according to the name of the target ending page and the name of the target starting page.
In an optional manner, the second determining module determines a second cropping interval of the target video, an initial cropping time of the target video, and an end cropping time according to a name of a first video end page and a name of a first video start page; the second cropping interval is smaller than the first cropping interval, including:
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment;
determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time;
subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration;
and determining a second cutting time interval according to the target duration.
A third aspect of the embodiments of the present invention provides an electronic device, including a memory and a processor, where the processor is configured to implement the steps of the method for testing page response duration according to the first aspect when executing a computer management class program stored in the memory.
A fourth aspect of the embodiments of the present invention provides a computer-readable storage medium, where at least one executable instruction is stored in the storage medium, and when the executable instruction runs on an electronic device, the electronic device is enabled to execute the operation of the method for testing a page response time length.
In summary, it can be seen that, in the embodiment provided by the embodiment of the present invention, the device for testing page response time may determine a first clipping time interval of the target video, clip the target video according to the first clipping time interval to obtain a first picture set, determine, from the first picture set, a first clipping page similar to the to-be-tested start page and the to-be-tested end page as a start point and an end point, calculate time duration between the start point and the end point again, determine a second clipping time interval again according to the time duration, thereby determine the target end page and the target start page, and determine the response time duration corresponding to the target page based on the target end page and the target start page. Therefore, in the embodiment of the invention, the time interval and the time length are calculated according to the name, and the clipping time interval can be set as small as possible when the target video is clipped for the second time, so that the testing precision of the response time length of the page is improved while the working efficiency is considered.
Drawings
The drawings are only for purposes of illustrating embodiments and are not to be construed as limiting the invention. Also, like reference numerals are used to refer to like parts throughout the drawings. In the drawings:
fig. 1 is a schematic flowchart of a method for testing page response duration according to an embodiment of the present invention;
fig. 2 is a schematic view of a virtual structure of a device for testing page response duration according to an embodiment of the present invention;
fig. 3 is a schematic diagram of an embodiment of an electronic device according to an embodiment of the present invention.
Detailed Description
The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically 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. 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.
The following describes a method for testing page response time from the perspective of a device for testing page response time.
Referring to fig. 1, fig. 1 is a schematic view of an embodiment of a method for testing page response time according to an embodiment of the present invention, where the method for testing page response time includes:
step 101: the method comprises the steps of obtaining a target video corresponding to a target application program, a start page to be tested and an end page to be tested corresponding to the target video.
In this embodiment, the device for testing page response duration may obtain a target Video corresponding to a target application, where the target Video includes at least one page to be tested for response duration, and the format of the target Video is not specifically limited herein, for example, MPEG (moving Picture Experts Group) may be an abbreviation of Motion Picture Experts Group, and Audio Video Interleaved (AVI), and of course, other formats may also be used, such as MOV format or MP4 format, which are not specifically limited. In addition, when the target video is obtained, screen recording can be performed from the time when the target application program is opened, pages needing to test the response time length are opened one by one until all the to-be-tested response time lengths in the target application program are opened and closed, and the target video is obtained. It can be understood that when the target video is obtained, the software for recording the video is generally opened for a preset time duration (for example, 5 seconds, although other time durations are also possible, specifically, without limitation), then the target application is opened, and after the target application is closed, the recording is continued for the preset time duration and then is ended, so that the subsequent page response time duration test is more accurate.
It should be noted that the target video may be a video corresponding to the target application program, or may be how many pages with test response time lengths, that is, how many videos, and each page with test response time length corresponds to one video, which is not limited specifically.
In the embodiment of the invention, the start page to be tested and the end page to be tested corresponding to the target video are stored in advance. The target video and the to-be-tested start page and the to-be-tested end page corresponding to the target video can be stored in the target folder path.
The start page to be tested and the end page to be tested are the start page and the end page corresponding to the page to be tested.
Step 102: analyzing the target video to obtain the frame rate of the target video, and determining the duration of the target video according to the frame rate.
In this embodiment, the target video may be a video file in various formats, and the duration is calculated by the following formula:
duration = total number of frames/frame rate.
The ffprobe may be used to extract the video frame rate, the total frame number, and the resolution information from the attribute information of the target video.
Step 103: and determining a first clipping time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video.
The page response duration testing device determines a first cutting time interval corresponding to a target page according to the duration of a target video, wherein the target page is any one page in the target video.
In the embodiment of the invention, the target video duration may be the operation process videos of a plurality of pages, however, the test may only need to test the buttons of a certain number of pages, and therefore, the operation processes of the pages before and after the certain number of pages can be ignored. Therefore, in the embodiment of the invention, a larger cutting time interval is considered to be set firstly, so that the intervals of the to-be-tested starting page and the to-be-tested ending page are quickly determined, and a smaller cutting time interval is set to perform higher-precision test.
Specifically, the first clipping time interval may be determined according to a first mapping relationship between a preset video duration and a time interval. The mapping relationship is a mapping relationship between a video length and a clipping time interval, and a first clipping time interval corresponding to a target page is determined according to the mapping relationship and the length of a target video, which is not specifically limited). It can be understood that: the longer the video length, the larger the cropping interval may be; conversely, the shorter the video length, the smaller the cropping interval may be.
For example, for a target video with a duration of 30 minutes, the first cropping interval may be set to 500 ms.
And configuring the time parameter corresponding to the target video according to the first time interval, so as to set a first cutting time interval of the first cutting process of the target video. The time parameter corresponding to the target page may be a time parameter included in a configuration file corresponding to the target application program, or may also be a time parameter included in another program, that is, when the clipping time interval corresponding to the target page is set, the time parameter in the configuration file corresponding to the target application program may be configured or the time parameter may be directly configured in the program, so as to achieve the purpose of determining the first clipping time interval corresponding to the target video.
In an embodiment of the present invention, before configuring the time parameter, first confirmation information is further sent to the user terminal, so that the user performs a confirmation operation according to the first confirmation information. The confirmation operation may be an operation in which the user terminal confirms whether or not the target video is clipped at the first clipping time interval. The confirmation operation at least comprises one of gesture operation, sliding operation, clicking operation and voice control operation.
Step 104: cutting the target video based on a first cutting time interval corresponding to the target page to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times.
The method comprises the steps of starting timing from an initial frame of a target video, and conducting cutting once at a first cutting time interval, so that a plurality of first cutting pages are obtained. Specifically, the method comprises the following steps:
cutting the target video from a first frame image of the target video to a last frame image of the target video by taking the first cutting time interval as a reference;
when the residual length of the target video is smaller than the cutting time interval, determining a video frame corresponding to the residual length of the target video;
and determining the last picture of the first picture set according to the video frame corresponding to the residual length of the target video.
And the name of each first cutting page is set according to the corresponding cutting times and the first cutting time interval. Specifically, the name naming rule is:
name of the first clipping page = first clipping interval × current clipping count.
For example, when the first cropping interval is 500ms, the current cropping is the 20 th cropping, and then 500 × 20=10000 is calculated. Therefore, the name of the first clipping page is obtained as follows: "10000", or "graph 10000 of the target application".
In the embodiment of the invention, the first picture set is stored into the target folder according to the cutting time sequence. Therefore, when the test operation of a plurality of target videos is carried out simultaneously, the first picture set is stored in association with each target video, the start page to be tested and the end page to be tested by setting different target folder paths, and the subsequent processing efficiency is improved.
Step 105: determining the first video starting page and the first video ending page from the first picture set according to a starting page to be tested and an ending page to be tested; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; and both the N and the M are more than or equal to 1.
The specific process of determining the first cutting page most similar to the initial page to be tested comprises the following steps: comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page;
performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the first similar page with the highest similarity of the target area as the first cutting page most similar to the starting page to be tested.
The specific process of determining the first cutting page most similar to the to-be-tested end page comprises the following steps:
comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page;
performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the second similar page with the highest similarity of the target area as the first cutting page most similar to the to-be-tested end page.
In the embodiment of the invention, as for the process of continuously changing the page to be tested, the page change before the adjacent two pages can be very weak. For example, when the response time of the "button" of the test page is long, the page as a whole does not change after the button is clicked, but the button itself may have a gray level change until the response is completed and the next page is skipped. However, since the responses of the general pages are all in millisecond order, when jumping to the next page, the responses are not desirable to finish the next page as soon as possible. What we need to test is only the change of the page where the "button" is located, and the middle change process is very weak, and if the similarity comparison is performed through the whole page, it cannot be determined whether the button reacts or changes. Therefore, enhancement processing is required for a target area (e.g., a button) in a page. The method comprises the steps of determining a target area according to target area information corresponding to a preset initial page to be tested and a preset end page to be tested, then performing enhancement processing on the target area, and comparing the similarity of the enhanced target area, thereby determining which first cutting page is most similar to the initial page to be tested and which first cutting page is most similar to the end page to be tested.
After determining a first clipping page most similar to the initial page to be tested and a first clipping page most similar to the end page to be tested, selecting an nth first clipping page arranged in front of the first clipping page most similar to the initial page to be tested as the first video start page, and selecting an mth first clipping page arranged behind the first clipping page most similar to the end page to be tested as the first video end page. Since the calculation is performed according to the clipping interval when the response test is performed, there may be a start page or an end page in the middle of one time interval. That is, there may be a start page and an end page of the target page between the two first clip pages. Therefore, after the most similar first cropping page is determined, the embodiment of the invention further delays forward and backward by a plurality of first cropping time intervals to serve as an initial frame and an end frame of the second cropping process.
Step 106: determining a second clipping time interval of the target video, the initial clipping time of the target video and the end clipping time according to the name of a first video end page and the name of a first video start page; the second clipping time interval is less than the first clipping time interval.
Wherein the specific step of determining the second clipping time interval comprises:
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment;
determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time;
subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration;
and determining a second cutting time interval according to the target duration.
Specifically, for example: the name of the first video end page is 2300, and the name of the first video start page is 1000, so that the two are subtracted to obtain 1300 ms. That is, the response time period from the first video start page to the first video end page is 1300 ms.
The process of determining a second clipping interval based on the target duration includes: and determining a second clipping time interval according to the target time length and a preset first mapping relation between the video time length and the time interval.
Since in the first mapping relationship, the longer the video time is, the larger the cropping time interval is. At this time, the video duration is the duration obtained by subtracting the duration corresponding to the first video start page from the first video end page. Therefore, the video duration becomes shorter, so the second cropping interval is smaller than the first cropping interval. And when the second cutting time interval is smaller than the first cutting time interval, the testing precision of the response time length is correspondingly improved. For example, the second cropping interval may be 50 ms.
Step 107: and cutting the target video from the initial cutting time according to the second cutting time interval until the cutting of the target video is finished at the cutting finishing time to obtain a second picture set, wherein the second picture set comprises a plurality of second cutting pages which are sequenced according to the cutting time sequence, and the names of the second cutting pages are named according to the second cutting time interval and the corresponding cutting times.
The target video is cropped from the initial cropping time according to the second cropping time interval until the end of the cropping time, and specifically, the position of the corresponding target video on the video player can be determined according to the initial cropping time. Dragging the player of the target video to the corresponding position to start playing, and starting to perform cutting operation. Similarly, the position of the target video corresponding to the cutting ending time on the video player is determined, and when the position is reached, the cutting is stopped.
In the embodiment of the invention, the second picture set is stored into the target folder according to the cutting time sequence. Therefore, when the test operation of a plurality of target videos is carried out simultaneously, the second picture set is stored in association with each target video, the start page to be tested and the end page to be tested by setting different target folder paths, and the subsequent processing efficiency is improved.
In the embodiment of the present invention, the specific implementation process of the second clipping process is the same as that in step 104, and is not described herein again.
Step 108: and determining a second cutting page which is most similar to the starting page to be tested in the second picture set as a target starting page, and determining a second cutting page which is most similar to the ending page to be tested in the second picture set as a target ending page.
Wherein, the general positions of the starting page to be tested and the ending page to be tested in the target video are already determined in the first cutting process. And after the second cutting, the third cutting operation is not needed. Only the most similar pages need to be compared. Therefore, through similarity comparison, a second cutting page most similar to the initial page to be tested is determined from a second picture set and is used as a target initial page; and determining a second cutting page which is most similar to the to-be-tested end page from the second picture set, and using the second cutting page as a target end page, namely finishing the confirmation of the start page and the end page of the to-be-tested page.
Step 109: and determining the response time length according to the name of the target ending page and the name of the target starting page.
For example, the second clipping time interval is 50ms, and when the name of the target end page is "1000" and the name of the target start page is "500", the response time length is: 1000-.
In summary, it can be seen that, in the embodiment provided by the embodiment of the present invention, the device for testing page response time may determine a first clipping time interval of the target video, clip the target video according to the first clipping time interval to obtain a first picture set, determine, from the first picture set, a first clipping page similar to the to-be-tested start page and the to-be-tested end page as a start point and an end point, calculate time duration between the start point and the end point again, determine a second clipping time interval again according to the time duration, thereby determine the target end page and the target start page, and determine the response time duration corresponding to the target page based on the target end page and the target start page. Therefore, in the embodiment of the invention, the time interval and the time length are calculated according to the name, and the clipping time interval can be set as small as possible when the target video is clipped for the second time, so that the testing precision of the response time length of the page is improved while the working efficiency is considered.
The above describes the method for testing the page response time length in the embodiment of the present invention, and the following describes the device for testing the page response time length in the embodiment of the present invention.
Referring to fig. 2, a schematic view of a virtual structure of a device for testing page response time according to an embodiment of the present invention, the device 200 for testing page response time includes:
a first obtaining module 201, configured to obtain a target video corresponding to a target application, a start page to be tested and an end page to be tested, where the start page and the end page correspond to the target video;
the analysis module 202 is configured to analyze the target video to obtain a frame rate of the target video, and determine a duration of the target video according to the frame rate;
a first determining module 203, configured to determine a first clipping time interval of a target page according to a duration of the target video, where the target page is any one page in the target video;
a first clipping module 204, configured to clip the target video based on a first clipping time interval corresponding to the target page to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
a first output page 205, configured to determine, according to a start page to be tested and an end page to be tested, the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
a second determining module 206, configured to determine, according to the name of the first video end page and the name of the first video start page, a second clipping time interval for the target video, an initial clipping time of the target video, and an end clipping time; the second clipping time interval is smaller than the first clipping time interval;
a second clipping module 207, configured to clip the target video from the initial clipping time according to the second clipping time interval until the end of clipping the target video, so as to obtain a second picture set, where the second picture set includes a plurality of second clipping pages ordered according to a clipping time sequence, and names of the second clipping pages are named according to the second clipping time interval and corresponding clipping times;
a third determining module 208, configured to determine that a second trimmed page, which is most similar to the start page to be tested, in the second picture set is a target start page, and determine that a second trimmed page, which is most similar to the end page to be tested, in the second picture set is a target end page;
a response duration determining module 209, configured to determine a response duration according to the name of the target end page and the name of the target start page.
The specific working process of the testing apparatus 200 for page response duration in the embodiment of the present invention is the same as the method steps in the above method embodiments, and is not described herein again.
In summary, it can be seen that, in the embodiment provided by the embodiment of the present invention, the device for testing page response time may determine a first clipping time interval of the target video, clip the target video according to the first clipping time interval to obtain a first picture set, determine, from the first picture set, a first clipping page similar to the to-be-tested start page and the to-be-tested end page as a start point and an end point, calculate time duration between the start point and the end point again, determine a second clipping time interval again according to the time duration, thereby determine the target end page and the target start page, and determine the response time duration corresponding to the target page based on the target end page and the target start page. Therefore, in the embodiment of the invention, the time interval and the time length are calculated according to the name, and the clipping time interval can be set as small as possible when the target video is clipped for the second time, so that the testing precision of the response time length of the page is improved while the working efficiency is considered.
Fig. 3 is a schematic structural diagram of an embodiment of the electronic device according to the present invention, and the specific embodiment of the present invention does not limit the specific implementation of the electronic device.
As shown in fig. 3, the electronic device may include: a processor (processor)302, a communication Interface 304, a memory 306, and a communication bus 308.
Wherein: the processor 302, communication interface 304, and memory 306 communicate with each other via a communication bus 308. A communication interface 304 for communicating with network elements of other devices, such as clients or other servers. The processor 302 is configured to execute the program 310, and may specifically execute relevant steps in the above-described test method embodiment for page response duration.
In particular, program 310 may include program code comprising computer-executable instructions.
The processor 302 may be a central processing unit CPU, or an Application Specific Integrated Circuit (ASIC), or one or more Integrated circuits configured to implement an embodiment of the present invention. The electronic device comprises one or more processors, which can be the same type of processor, such as one or more CPUs; or may be different types of processors such as one or more CPUs and one or more ASICs.
And a memory 306 for storing a program 310. Memory 306 may comprise high-speed RAM memory and may also include non-volatile memory (non-volatile memory), such as at least one disk memory.
Specifically, the program 310 may be invoked by the processor 302 to cause the electronic device to perform the following operations:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video;
analyzing the target video to obtain a frame rate of the target video, and determining the duration of the target video according to the frame rate;
determining a first clipping time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
cutting the target video based on a first cutting time interval corresponding to the target page to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
determining the first video starting page and the first video ending page from the first picture set according to a starting page to be tested and an ending page to be tested; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
determining a second clipping time interval of the target video, the initial clipping time of the target video and the end clipping time according to the name of a first video end page and the name of a first video start page; the second clipping time interval is smaller than the first clipping time interval;
cutting the target video from the initial cutting time according to the second cutting time interval until the cutting of the target video is finished at the cutting finishing time to obtain a second picture set, wherein the second picture set comprises a plurality of second cutting pages which are sequenced according to a cutting time sequence, and the names of the second cutting pages are named according to the second cutting time interval and the corresponding cutting times;
determining a second cutting page which is most similar to the starting page to be tested in the second picture set as a target starting page, and determining a second cutting page which is most similar to the ending page to be tested in the second picture set as a target ending page;
and determining the response time length according to the name of the target ending page and the name of the target starting page.
In an optional manner, the target video is cropped based on a first cropping time interval corresponding to the target page, so as to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and comprise:
cutting the target video from a first frame image of the target video to a last frame image of the target video by taking the first cutting time interval as a reference;
when the residual length of the target video is smaller than the cutting time interval, determining a video frame corresponding to the residual length of the target video;
and determining the last picture of the first picture set according to the video frame corresponding to the residual length of the target video.
In an optional mode, determining a second clipping time interval of the target video, an initial clipping time of the target video and an end clipping time according to a name of a first video end page and a name of a first video start page; the second cropping interval is smaller than the first cropping interval, including:
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment;
determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time;
subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration;
and determining a second cutting time interval according to the target duration.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page;
performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the first similar page with the highest similarity of the target area as the first cutting page most similar to the starting page to be tested.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page;
performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the second similar page with the highest similarity of the target area as the first cutting page most similar to the to-be-tested end page.
In an optional manner, acquiring a target video corresponding to a target application program, a start page to be tested and an end page to be tested corresponding to the target video includes:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video from a target folder path;
the target video is cut based on a first cutting time interval corresponding to the target page, so that a first picture set corresponding to the target video is obtained; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and the names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and the method comprises the following steps:
and storing the first picture set into the target folder according to the cutting time sequence.
The embodiment of the invention provides a computer-readable storage medium, wherein at least one executable instruction is stored in the storage medium, and when the executable instruction runs on electronic equipment, the electronic equipment is enabled to execute the method for testing the page response time length in any method embodiment.
The executable instructions may be specifically configured to cause the electronic device to perform the following operations:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video;
analyzing the target video to obtain a frame rate of the target video, and determining the duration of the target video according to the frame rate;
determining a first clipping time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
cutting the target video based on a first cutting time interval corresponding to the target page to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
determining the first video starting page and the first video ending page from the first picture set according to a starting page to be tested and an ending page to be tested; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
determining a second clipping time interval of the target video, the initial clipping time of the target video and the end clipping time according to the name of a first video end page and the name of a first video start page; the second clipping time interval is smaller than the first clipping time interval;
cutting the target video from the initial cutting time according to the second cutting time interval until the cutting of the target video is finished at the cutting finishing time to obtain a second picture set, wherein the second picture set comprises a plurality of second cutting pages which are sequenced according to a cutting time sequence, and the names of the second cutting pages are named according to the second cutting time interval and the corresponding cutting times;
determining a second cutting page which is most similar to the starting page to be tested in the second picture set as a target starting page, and determining a second cutting page which is most similar to the ending page to be tested in the second picture set as a target ending page;
and determining the response time length according to the name of the target ending page and the name of the target starting page.
In an optional manner, the target video is cropped based on a first cropping time interval corresponding to the target page, so as to obtain a first picture set corresponding to the target video; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and comprise:
cutting the target video from a first frame image of the target video to a last frame image of the target video by taking the first cutting time interval as a reference;
when the residual length of the target video is smaller than the cutting time interval, determining a video frame corresponding to the residual length of the target video;
and determining the last picture of the first picture set according to the video frame corresponding to the residual length of the target video.
In an optional mode, determining a second clipping time interval of the target video, an initial clipping time of the target video and an end clipping time according to a name of a first video end page and a name of a first video start page; the second cropping interval is smaller than the first cropping interval, including:
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment;
determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time;
subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration;
and determining a second cutting time interval according to the target duration.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page;
performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the first similar page with the highest similarity of the target area as the first cutting page most similar to the starting page to be tested.
In an optional mode, according to a start page to be tested and an end page to be tested, determining the first video start page and the first video end page from the first picture set; the first video starting page is an Nth first clipping page in front of a first clipping page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; n and M are both greater than or equal to 1, including:
comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page;
performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page;
calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page;
and determining the second similar page with the highest similarity of the target area as the first cutting page most similar to the to-be-tested end page.
In an optional manner, acquiring a target video corresponding to a target application program, a start page to be tested and an end page to be tested corresponding to the target video includes:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video from a target folder path;
the target video is cut based on a first cutting time interval corresponding to the target page, so that a first picture set corresponding to the target video is obtained; the first picture set comprises a plurality of first clipping pages which are sequenced according to a clipping time sequence, and the names of the first clipping pages are named according to the first clipping time interval and the corresponding clipping times, and the method comprises the following steps:
and storing the first picture set into the target folder according to the cutting time sequence.
Embodiments of the present invention provide a computer program, where the computer program can be called by a processor to enable an electronic device to execute a test method for a page response duration in any of the above method embodiments.
Embodiments of the present invention provide a computer program product, which includes a computer program stored on a computer-readable storage medium, where the computer program includes program instructions, and when the program instructions are run on a computer, the computer is caused to execute the method for testing page response duration in any of the above-mentioned method embodiments.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
An embodiment of the present invention further provides a computer program product, where the computer program product includes computer software instructions, and when the computer software instructions are run on a processing device, the processing device is caused to execute a flow in the method for testing a page response duration in the embodiment corresponding to fig. 1.
The computer program product includes one or more computer instructions. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to occur, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored on a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website, computer, server, or data center to another website, computer, server, or data center via wire (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that a computer can store or a data storage device, such as a server, a data center, etc., that is integrated with one or more available media. The usable medium may be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the embodiments provided in the present invention, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or 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, devices or units, and may be in an electrical, mechanical 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 integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a 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 instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (4)

1. A method for testing page response duration is characterized by comprising the following steps:
acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video from a target folder path;
analyzing the target video to obtain a frame rate of the target video, and determining the duration of the target video according to the frame rate;
determining a first clipping time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
cutting the target video from a first frame image of the target video to a last frame image of the target video by taking the first cutting time interval as a reference; when the residual length of the target video is smaller than the first cutting time interval, determining a video frame corresponding to the residual length of the target video; determining the last picture of a first picture set according to the video frame corresponding to the residual length of the target video to obtain the first picture set corresponding to the target video, and storing the first picture set into the target folder according to the cutting time sequence; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page; performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page; calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page; determining a first similar page with the highest similarity of a target area as a first cutting page most similar to the initial page to be tested; comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page; performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page; calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page; determining a second similar page with the highest similarity of the target area as a first cutting page most similar to the to-be-tested end page; the first video starting page is an Nth first cutting page in front of a first cutting page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
determining a first position of the first video starting page corresponding to the target video according to the name of the first video starting page, and taking the first position as an initial clipping moment; determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time; subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration; determining a second cutting time interval according to the target duration; the second clipping time interval is smaller than the first clipping time interval;
cutting the target video from the initial cutting time according to the second cutting time interval until the cutting of the target video is finished at the cutting finishing time to obtain a second picture set, wherein the second picture set comprises a plurality of second cutting pages which are sequenced according to a cutting time sequence, and the names of the second cutting pages are named according to the second cutting time interval and the corresponding cutting times;
determining a second cutting page which is most similar to the starting page to be tested in the second picture set as a target starting page, and determining a second cutting page which is most similar to the ending page to be tested in the second picture set as a target ending page;
and determining the response time length according to the name of the target ending page and the name of the target starting page.
2. A page response duration testing device is characterized by comprising:
the first acquisition module is used for acquiring a target video corresponding to a target application program, a to-be-tested start page and a to-be-tested end page corresponding to the target video from a target folder path;
the analysis module is used for analyzing the target video to obtain the frame rate of the target video and determining the duration of the target video according to the frame rate;
the first determining module is used for determining a first cutting time interval of a target page according to the duration of the target video, wherein the target page is any one page in the target video;
the first cropping module is used for cropping the target video from a first frame image of the target video to a last frame image of the target video by taking the first cropping time interval as a reference; when the residual length of the target video is smaller than the first cutting time interval, determining a video frame corresponding to the residual length of the target video; determining the last picture of a first picture set according to the video frame corresponding to the residual length of the target video to obtain the first picture set corresponding to the target video, and storing the first picture set into the target folder according to the cutting time sequence; the first picture set comprises a plurality of first cutting pages which are sequenced according to a cutting time sequence, and the names of the first cutting pages are named according to the first cutting time interval and the corresponding cutting times;
the first output page is used for comparing the similarity of the starting page to be tested with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a first similar page; performing image enhancement processing on the target area of the starting page to be tested and the target area of the at least one first similar page; calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page; determining a first similar page with the highest similarity of a target area as a first cutting page most similar to the initial page to be tested; comparing the similarity of the to-be-tested end page with a plurality of first cutting pages in the first picture set to obtain at least one first cutting page with the similarity larger than a first threshold value as a second similar page; performing image enhancement processing on the target area of the to-be-tested end page and the target area of the at least one second similar page; calculating the similarity between the target area of the enhanced to-be-tested initial page and the target area of at least one first similar page; determining a second similar page with the highest similarity of the target area as a first cutting page most similar to the to-be-tested end page; the first video starting page is an Nth first cutting page in front of a first cutting page which is most similar to the starting page to be tested in the first picture set; the first video end page is an Mth first cut page behind a first cut page which is most similar to the end page to be tested in the first picture set; both N and M are greater than or equal to 1;
a second determining module, configured to determine, according to the name of the first video start page, a first position in the target video corresponding to the first video start page, and use the first position as an initial clipping time; determining a second position in the target video corresponding to the first video end page according to the name of the first video end page, and taking the second position as the cutting end time; subtracting the name of the first video starting page from the name of the first video ending page to obtain a target duration; determining a second cutting time interval according to the target duration; the second clipping time interval is smaller than the first clipping time interval;
the second clipping module is used for clipping the target video from the initial clipping moment according to the second clipping time interval until the clipping of the target video is finished at the clipping finishing moment to obtain a second picture set, wherein the second picture set comprises a plurality of second clipping pages which are sequenced according to the clipping time sequence, and the names of the second clipping pages are named according to the second clipping time interval and the corresponding clipping times;
a third determining module, configured to determine that a second clipping page, which is most similar to the start page to be tested, in the second picture set is a target start page, and determine that a second clipping page, which is most similar to the end page to be tested, in the second picture set is a target end page;
and the response time length determining module is used for determining the response time length according to the name of the target ending page and the name of the target starting page.
3. An electronic device comprising a memory and a processor, wherein the processor is configured to implement the steps of the method for testing page response time according to claim 1 when executing a computer management class program stored in the memory.
4. A computer-readable storage medium having stored therein at least one executable instruction, which when run on an electronic device, causes the electronic device to perform the operations of the page response time duration testing method of claim 1.
CN202011348490.6A 2020-11-26 2020-11-26 Page response duration testing method and related equipment Active CN112306892B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011348490.6A CN112306892B (en) 2020-11-26 2020-11-26 Page response duration testing method and related equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011348490.6A CN112306892B (en) 2020-11-26 2020-11-26 Page response duration testing method and related equipment

Publications (2)

Publication Number Publication Date
CN112306892A CN112306892A (en) 2021-02-02
CN112306892B true CN112306892B (en) 2022-04-12

Family

ID=74487062

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011348490.6A Active CN112306892B (en) 2020-11-26 2020-11-26 Page response duration testing method and related equipment

Country Status (1)

Country Link
CN (1) CN112306892B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115866343B (en) * 2022-12-08 2024-03-12 四川长虹电器股份有限公司 Method for testing focus moving time based on image page average brightness comparison

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015196601A1 (en) * 2014-06-23 2015-12-30 中兴通讯股份有限公司 Method, apparatus and device for testing response time of user interface, and storage medium
CN106802935A (en) * 2016-12-29 2017-06-06 腾讯科技(深圳)有限公司 The method of testing and device of a kind of page fluency
CN107678895A (en) * 2017-09-11 2018-02-09 上海斐讯数据通信技术有限公司 A kind of method of testing and system of intelligent terminal page jump time

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070079291A1 (en) * 2005-09-27 2007-04-05 Bea Systems, Inc. System and method for dynamic analysis window for accurate result analysis for performance test

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2015196601A1 (en) * 2014-06-23 2015-12-30 中兴通讯股份有限公司 Method, apparatus and device for testing response time of user interface, and storage medium
CN106802935A (en) * 2016-12-29 2017-06-06 腾讯科技(深圳)有限公司 The method of testing and device of a kind of page fluency
CN107678895A (en) * 2017-09-11 2018-02-09 上海斐讯数据通信技术有限公司 A kind of method of testing and system of intelligent terminal page jump time

Also Published As

Publication number Publication date
CN112306892A (en) 2021-02-02

Similar Documents

Publication Publication Date Title
CN106802935B (en) Page fluency testing method and device
CN110730387B (en) Video playing control method and device, storage medium and electronic device
CN111552633A (en) Interface abnormal call testing method and device, computer equipment and storage medium
CN109743589B (en) Article generation method and device
CN109032470A (en) Screenshot method, device, terminal and computer readable storage medium
CN112685672B (en) Page session behavior trace backtracking method and device and electronic equipment
CN112306892B (en) Page response duration testing method and related equipment
CN110781349A (en) Method, equipment, client device and electronic equipment for generating short video
CN109271929B (en) Detection method and device
CN109429093B (en) Video editing method and terminal
CN108769549B (en) Image processing method and device and computer readable storage medium
CN104700830B (en) A kind of sound end detecting method and device
CN111147778B (en) Track recording method and device based on digital video recorder and storage medium
CN112752127B (en) Method and device for positioning video playing position, storage medium and electronic device
CN112306870A (en) Data processing method and device based on live APP
CN110536077B (en) Video synthesis and playing method, device and equipment
CN110688602A (en) Method, device and system for testing webpage loading speed
CN114245171B (en) Video editing method and device, electronic equipment and medium
CN110058991A (en) A kind of automatic test approach and system of application software
CN115757165A (en) Automatic testing method, device, equipment and storage medium
CN113269658A (en) Method, device and equipment for estimating production time of core data and storage medium
CN115454873A (en) Application interface testing method and device based on flow playback
CN111123744B (en) Menu recording method and device, storage medium and electronic equipment
CN109213906B (en) Session duration calculation method, device and system
CN112463746A (en) File storage and generation method and device and electronic equipment

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