[go: up one dir, main page]

CN104731694B - Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system - Google Patents

Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system Download PDF

Info

Publication number
CN104731694B
CN104731694B CN201310697428.1A CN201310697428A CN104731694B CN 104731694 B CN104731694 B CN 104731694B CN 201310697428 A CN201310697428 A CN 201310697428A CN 104731694 B CN104731694 B CN 104731694B
Authority
CN
China
Prior art keywords
comparison
browsers
picture
index table
display
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
CN201310697428.1A
Other languages
Chinese (zh)
Other versions
CN104731694A (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.)
China Unionpay Co Ltd
Original Assignee
China Unionpay 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 China Unionpay Co Ltd filed Critical China Unionpay Co Ltd
Priority to CN201310697428.1A priority Critical patent/CN104731694B/en
Publication of CN104731694A publication Critical patent/CN104731694A/en
Application granted granted Critical
Publication of CN104731694B publication Critical patent/CN104731694B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Debugging And Monitoring (AREA)

Abstract

本发明涉及浏览器兼容性测试分析方法和测试分析系统。该浏览器兼容性测试分析方法包括下述步骤:待测系统显示步骤,以相同的显示方式在不同的浏览器上,使得显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;图片编码索引表建立步骤,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表,图片比对步骤,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及测试报告生成步骤,根据比对结果生成测试报告。利用本发明,能够提高浏览器兼容性测试的效率和准确性。

The invention relates to a browser compatibility test analysis method and a test analysis system. This browser compatibility test analysis method comprises the following steps: the system under test display step, with the same display mode on different browsers, so that the interactive interface of the software system to be tested is displayed and the display of each interactive interface is saved Screenshot; image coding index table establishment step, image preprocessing is performed on the saved screenshot to extract multi-dimensional feature values, and according to the extracted multi-dimensional feature values, a picture coding index table is established for each screenshot, and the image comparison step is based on The image coding index table performs batch comparison on the display results of each interactive interface on different browsers and generates comparison results; and the test report generation step generates a test report according to the comparison results. The invention can improve the efficiency and accuracy of the browser compatibility test.

Description

浏览器兼容性测试分析方法及浏览器兼容性测试分析系统Browser Compatibility Test Analysis Method and Browser Compatibility Test Analysis System

技术领域technical field

本发明涉及浏览器兼容性测试技术领域,特别地涉及软件用户界面的浏览器兼容测试方法和系统。The invention relates to the technical field of browser compatibility testing, in particular to a browser compatibility testing method and system for software user interfaces.

背景技术Background technique

目前的软件系统一般需要支持多种浏览器,由于不同浏览器的内核、呈现引擎、JavaScript 解释器以及数据存储之间存在差别,导致软件系统在不同浏览器之间的存在兼容性的问题。针对浏览器的兼容性测试目前一般以手工测试为主,需要对不同浏览器的显示结果人工进行比对分析。Current software systems generally need to support multiple browsers. Due to differences in the kernels, rendering engines, JavaScript interpreters, and data storage of different browsers, software systems have compatibility issues among different browsers. At present, the compatibility testing for browsers is generally based on manual testing, which requires manual comparison and analysis of the display results of different browsers.

同一款软件的用户界面设计会在不同浏览器之间存在显示的差异,如何准确测试不同浏览器之间的兼容性,一直是困扰测试人员的难题。目前对浏览器兼容性的测试,一般依赖于测试人员的手工检查和肉眼识别,普遍存在三个问题:The user interface design of the same software will be displayed differently among different browsers. How to accurately test the compatibility between different browsers has always been a difficult problem for testers. At present, browser compatibility tests generally rely on manual inspection and visual identification by testers, and there are three common problems:

1.测试界面比对元素易遗漏;1. The test interface comparison elements are easy to miss;

2.测试比对效率低,并且过度依赖特定测试人员的素质;2. The efficiency of test comparison is low, and it is overly dependent on the quality of specific testers;

3.测试准确性不高,测试过程中的比对基准不明确。3. The test accuracy is not high, and the comparison benchmark in the test process is not clear.

同时随着互联网经济不断发展,为紧跟市场脚步软件系统的界面设计会经常发生修改,这对于软件系统界面的测试提出了更高的要求。At the same time, with the continuous development of the Internet economy, the interface design of the software system will often be revised in order to keep up with the pace of the market, which puts forward higher requirements for the testing of the software system interface.

发明内容Contents of the invention

鉴于上述问题,本发明旨在提供一种能够提高用户界面的兼容性测试效率和准确性的浏览器兼容性测试分析方法及浏览器兼容性测试分析系统。In view of the above problems, the present invention aims to provide a browser compatibility test analysis method and a browser compatibility test analysis system capable of improving the efficiency and accuracy of user interface compatibility test.

本发明的浏览器兼容性测试分析方法,其特征在于,包括下述步骤:The browser compatibility test analysis method of the present invention is characterized in that, comprises the following steps:

待测系统显示步骤,以相同的显示方式在不同的浏览器上,使得显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;The display step of the system to be tested is to display the interactive interface of the software system to be tested on different browsers in the same display mode and save the screenshot for the display of each interactive interface;

图片编码索引表建立步骤,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表;The step of establishing a picture coding index table is to perform picture preprocessing on the saved screenshots to extract multi-dimensional feature values, and to establish a picture coding index table for each screenshot according to the extracted multi-dimensional feature values;

图片比对步骤,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及Picture comparing step, according to described picture encoding index table, carry out batch comparison to the display result of each interactive interface on different browsers and generate comparison result; And

测试报告生成步骤,根据比对结果生成测试报告。The test report generating step is to generate a test report according to the comparison result.

优选地,在所述待测系统显示步骤中,所述以相同的显示方式在不同的浏览器上是指,选择尺寸和分辨率相同的多个显示器并安装不同的浏览器或者在一台显示器上安装不同的浏览器,同时剔除浏览器的第三方插件。Preferably, in the step of displaying the system under test, the same display method on different browsers refers to selecting a plurality of displays with the same size and resolution and installing different browsers or displaying them on one display Install different browsers on the Internet, and remove third-party plug-ins from the browser.

优选地,在所述图片编码索引表建立步骤中,对保存的截图进行图片预处理,以提取颜色特征值、纹理特征值、空间关系特征值,并且根据这三个特征值对每张截图建立图片编码索引表。Preferably, in the step of establishing the picture coding index table, the stored screenshots are subjected to picture preprocessing to extract color feature values, texture feature values, and spatial relationship feature values, and each screenshot is established according to these three feature values. Image encoding index table.

优选地,所述图片编码索引表建立步骤包括下述子步骤:Preferably, the step of establishing the picture coding index table includes the following sub-steps:

颜色特征提取步骤,对保存的截图进行图片预处理以提取表示颜色分布的颜色矩;The color feature extraction step is to carry out image preprocessing to the saved screenshot to extract the color moment representing the color distribution;

纹理特征提取步骤,对保存的截图中包含多个像素点进行统计计算,以获取表述图像的表面性质的纹理特征;以及A texture feature extraction step, performing statistical calculations on multiple pixels contained in the saved screenshot, so as to obtain texture features representing the surface properties of the image; and

空间关系特征提取步骤,对保存的截图中的多个目标之间的相互的空间位置或相对方向关系进行计算得到空间关系特征。The spatial relationship feature extraction step is to calculate the mutual spatial position or relative direction relationship between multiple objects in the saved screenshot to obtain the spatial relationship feature.

优选地,所述颜色矩包括下述特征:一阶矩、二阶矩、三阶矩,Preferably, the color moments include the following features: first-order moments, second-order moments, third-order moments,

所述纹理特征包括下述特征:纹理粗细度、方向性,The texture features include the following features: texture thickness, directionality,

所述空间关系特征包括下述特征:连接关系、邻接关系、交叠关系、重叠关系、包含关系、包容关系。The spatial relationship features include the following features: connection relationship, adjacency relationship, overlap relationship, overlap relationship, containment relationship, containment relationship.

优选地,在所述图片比对步骤中,以规定的浏览器为比对基准,按照图片编号查找图片编码索引表,对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果。Preferably, in the picture comparison step, the specified browser is used as the comparison benchmark, and the picture coding index table is searched according to the picture number, and the display results of each interactive interface on different browsers are compared in batches to generate a comparison. to the result.

优选地,在所述图片比对步骤中,能够以根据需要摒弃上述项目中的规定项目的方式进行批量比对并生成比对结果。Preferably, in the step of comparing pictures, it is possible to perform batch comparison and generate a comparison result by omitting prescribed items among the above-mentioned items as required.

优选地,在所述图片比对步骤中,进行图片特征索引位匹配。Preferably, in the step of comparing pictures, bit matching of feature indexes of pictures is performed.

优选地,所述图片特征索引位匹配包括下述子步骤:Preferably, said picture feature index bit matching includes the following sub-steps:

对于两个浏览器的某个特征值,读取预先设定的规定数值范围;For a characteristic value of the two browsers, read the preset specified value range;

判断两个浏览器的某个特征值之差是否在该预设的规定数值范围内;Determine whether the difference between a characteristic value of the two browsers is within the preset specified value range;

如果在该规定范围内,则判断为两个浏览器的该特征值为相同,否则,判断为两个浏览器的该特征值为不相同。If it is within the specified range, it is determined that the characteristic values of the two browsers are the same; otherwise, it is determined that the characteristic values of the two browsers are different.

本发明的浏览器兼容性测试分析系统,其特征在于,包括:The browser compatibility test and analysis system of the present invention is characterized in that it includes:

显示方式相同的不同的浏览器,用于显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;Different browsers with the same display mode are used to display the interactive interface of the software system to be tested and save screenshots of the display of each interactive interface;

图片编码索引表建立模块,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表;The image encoding index table building module is used to perform image preprocessing on the saved screenshots to extract multi-dimensional feature values, and establish an image encoding index table for each screenshot according to the extracted multi-dimensional feature values;

图片比对模块,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及The picture comparison module performs batch comparison on the display results of each interactive interface on different browsers according to the picture coding index table and generates comparison results; and

测试报告生成模块,根据比对结果生成测试报告。The test report generation module generates a test report according to the comparison result.

优选地,所述显示方式相同的不同的浏览器是指,选择尺寸和分辨率相同的多个显示器并安装不同的浏览器或者在一台显示器上安装不同的浏览器,同时剔除浏览器的第三方插件。Preferably, the different browsers with the same display mode refer to selecting a plurality of monitors with the same size and resolution and installing different browsers or installing different browsers on one monitor, and removing the browser's first browser at the same time. Three-party plug-ins.

根据本发明的浏览器兼容性测试分析方法及浏览器兼容性测试分析系统,能够对待测软件系统在不同浏览器上的显示结果进行批量自动分析比对,并能够通过配置文件灵活控制比对的信息位图摒弃不敏感的比对信息,比对完成后将比对结果自动生成测试报告。因此,利用本发明,能够提高浏览器兼容性测试的效率和准确性。According to the browser compatibility test and analysis method and browser compatibility test and analysis system of the present invention, the display results of the software system to be tested on different browsers can be automatically analyzed and compared in batches, and the comparison can be flexibly controlled through configuration files The information bitmap discards insensitive comparison information, and after the comparison is completed, the comparison results will automatically generate a test report. Therefore, using the present invention, the efficiency and accuracy of browser compatibility testing can be improved.

附图说明Description of drawings

图1是本发明的浏览器兼容性测试分析方法的流程示意图。FIG. 1 is a schematic flowchart of the browser compatibility testing and analyzing method of the present invention.

图2是表示本发明的浏览器兼容性测试分析方法中图片编码索引表建立步骤的具体流程图。Fig. 2 is a specific flow chart showing the steps of establishing an image encoding index table in the browser compatibility testing and analyzing method of the present invention.

图3是表示本发明的浏览器兼容性测试分析方法中基于图片编码索引表进行比对的流程图。Fig. 3 is a flow chart showing the comparison based on the picture coding index table in the browser compatibility testing and analysis method of the present invention.

具体实施方式Detailed ways

下面介绍的是本发明的多个实施例中的一些,旨在提供对本发明的基本了解。并不旨在确认本发明的关键或决定性的要素或限定所要保护的范围。Introduced below are some of the various embodiments of the invention, intended to provide a basic understanding of the invention. It is not intended to identify key or critical elements of the invention or to delineate the scope of protection.

在本发明的主要技术方案是,首先将待测软件系统的交互界面设计中所有存在的界面在不同的浏览器上进行显示,显示前保证浏览器的分辨率和尺寸大小一致,并剔除浏览器第三方插件,降低对测试结果的影响。然后,对每种浏览器显示的图片截图后保持分析,提取图片的特征值,建立特征值索引表。接着,以指定的浏览器显示结果为比对基准分别对其余浏览器的显示结果进行批量比对并生成测试报告,在比对的过程中允许通过配置文件达到差异域的阀值控制,达到相似度的比对预期。The main technical solution of the present invention is to firstly display all existing interfaces in the interactive interface design of the software system to be tested on different browsers, ensure that the resolution and size of the browsers are consistent before displaying, and eliminate browsers. Third-party plug-ins reduce the impact on test results. Then, keep analyzing the screenshots of the pictures displayed by each browser, extract the feature values of the pictures, and build a feature value index table. Then, use the specified browser display results as the comparison benchmark to perform batch comparison of the display results of other browsers and generate a test report. During the comparison process, it is allowed to achieve the threshold control of the difference domain through the configuration file to achieve similarity. degrees compared to expectations.

下面首先对于本发明的浏览器兼容性测试分析方法进行说明。Firstly, the browser compatibility test and analysis method of the present invention will be described below.

图1是本发明的浏览器兼容性测试分析方法的流程图示意图。FIG. 1 is a schematic flowchart of the browser compatibility testing and analysis method of the present invention.

如图1所示,本发明的浏览器兼容性测试分析方法主要包括下述步骤:As shown in Figure 1, the browser compatibility test analysis method of the present invention mainly comprises the following steps:

待测系统显示步骤:选择尺寸和分辨率相同的N个显示器(在图1中示为浏览器1、浏览器2、浏览器3、浏览器N)并且安装不同的浏览器,或者在同一台显示器上安装不同的浏览器。将待测的界面系统即待测试的软件系统的交互界面输入到浏览器1、浏览器1、浏览器2、浏览器3、浏览器N并且对每个交互界面的显示保存截图;Display steps of the system to be tested: select N monitors with the same size and resolution (shown as browser 1, browser 2, browser 3, and browser N in Figure 1) and install different browsers, or A different browser is installed on the monitor. Input the interactive interface of the interface system to be tested, that is, the software system to be tested, into browser 1, browser 1, browser 2, browser 3, browser N and save screenshots for the display of each interactive interface;

图片编码索引表建立步骤:对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表(图1中未图示);The step of establishing the picture coding index table: preprocessing the saved screenshots to extract multi-dimensional feature values, and building a picture coding index table for each screenshot according to the extracted multi-dimensional feature values (not shown in Figure 1);

图片比对步骤:指定浏览器1~N中的一款浏览器(例如主流浏览)为基准,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及Image comparison step: specify a browser among browsers 1 to N (such as mainstream browsers) as a benchmark, and perform batch comparison and generation of the display results of each interactive interface on different browsers according to the image encoding index table comparison results; and

测试报告生成步骤:根据比对结果生成测试报告。Test report generation step: generate a test report according to the comparison results.

图2是表示本发明的浏览器兼容性测试分析方法中图片编码索引表建立步骤的具体流程图。Fig. 2 is a specific flow chart showing the steps of establishing an image encoding index table in the browser compatibility testing and analyzing method of the present invention.

如图2所示,在所述图片编码索引表建立步骤中,首先对保存的截图进行图片预处理,然后分别对界面图片的颜色特征、纹理特征、空间关系特征这三个纬度进行匹配,最后将图片特征值汇总,建立图片编码索引表。As shown in Figure 2, in the step of establishing the picture coding index table, firstly carry out picture preprocessing to the saved screenshot, then respectively match the three latitudes of the color feature, texture feature and spatial relationship feature of the interface picture, and finally Summarize the feature values of the pictures to establish a picture coding index table.

其中,颜色特征描述了图像基于像素点的性质。图像中任何的颜色分布均可以用它的矩来表示。颜色分布信息主要集中在低阶矩中,采用颜色的一阶矩(mean)、二阶矩(variance)和三阶矩(skewness)以表达图像的颜色分布。获取图片的颜色矩并进行颜色编码,得到软件界面系统背景、前景色以及阴影的颜色层次的信息。Among them, the color feature describes the nature of the image based on pixels. Any color distribution in an image can be represented by its moments. The color distribution information is mainly concentrated in the low-order moment, and the first-order moment (mean), second-order moment (variance) and third-order moment (skewness) of the color are used to express the color distribution of the image. Obtain the color moment of the picture and perform color coding to obtain the information of the background, foreground color and shadow color level of the software interface system.

纹理特征是一种全局特征,描述的是图像的表面性质。对包含多个像素点的区域中进行统计计算,以获取图片纹理的粗细度及方向性等特征参数的信息。Texture feature is a global feature that describes the surface properties of an image. Statistical calculations are performed on an area containing multiple pixels to obtain information on characteristic parameters such as the thickness and directionality of the image texture.

空间关系是指图像中分割出来的多个目标之间的相互的空间位置或相对方向关系,这些关系也可分为连接、邻接、交叠、重叠、包含、包容等关系。通过分析图片中的空间关系可以得到软件界面中的录入框、信息展示、下拉框等之间的布局信息。Spatial relationship refers to the mutual spatial position or relative direction relationship between multiple objects segmented in the image. These relationships can also be divided into connection, adjacency, overlap, overlap, containment, containment and other relationships. By analyzing the spatial relationship in the picture, the layout information among the entry box, information display, drop-down box, etc. in the software interface can be obtained.

接着,对于颜色特征、纹理特征、空间关系特征这三个纬度分别建立的特征值索引表进行说明。Next, the feature value index tables established respectively for the three latitudes of color features, texture features, and spatial relationship features will be described.

表1是表示颜色特征的索引表。Table 1 is an index table representing color features.

表1Table 1

颜色特征color characteristics 一阶矩first moment 二阶矩second moment 三阶矩third moment 浏览器1browser 1 A1A1 A2A2 A3A3 浏览器2browser 2 B1B1 B2B2 B3B3 ……... X1X1 X2X2 X3X3 浏览器NbrowserN N1N1 N2N2 N3N3

A1、A2、A3表示一张图片在浏览器1上显示的特征值,B1、B2、B3表示一张图片在浏览器2上显示的特征值,N1、 N2 、N3表示一张图片在浏览器N上显示的特征值。A1, A2, A3 represent the feature value of a picture displayed on browser 1, B1, B2, B3 represent the feature value of a picture displayed on browser 2, N1, N2, N3 represent the feature value of a picture displayed on browser 1 The eigenvalues shown on N.

如下述这样比较浏览器1~N的颜色特征的数值:Compare the values of the color features of browsers 1~N as follows:

比较一阶矩的特征值:对A1、 B1、 X1…N1进行比较;Compare the eigenvalues of the first moments: compare A1, B1, X1...N1;

比较二阶矩的特征值:对A2 、B2、 X2 …N2进行比较;Compare the eigenvalues of the second moments: compare A2, B2, X2...N2;

比较三阶矩的特征值:对A3 、B3、 X3…N3进行比较。Compare the eigenvalues of the third moments: compare A3, B3, X3...N3.

表2是表示纹理特征的索引表。在表2中作为纹理特征仅仅示例性地表示了纹理粗细度、方向性,还可以包含其余特征,在此不一一列举。Table 2 is an index table representing texture features. In Table 2, texture thickness and directionality are only exemplified as texture features, and other features may also be included, which are not listed here one by one.

表2Table 2

纹理特征texture features 纹理粗细度texture thickness 方向性directionality 其余特征other features 浏览器1browser 1 Aa1Aa1 Aa2Aa2 ….. … 浏览器2browser 2 Bb1Bb1 Bb2Bb2 ….. … ……... Xx1Xx1 Xx2Xx2 ….. … 浏览器NbrowserN Nn1Nn1 Nn2N2 ……...

如下述这样比较浏览器1~N的纹理特征的数值:Compare the values of the texture features of browsers 1~N as follows:

比较纹理粗细度的特征值:对Aa1 、Bb1、 Xx1、 Nn1进行比较了;Compare the eigenvalues of texture thickness: Aa1, Bb1, Xx1, Nn1 are compared;

比较方向性的特征值:对Aa2、 Bb2、 Xx2、 Nn2进行比较。Comparing eigenvalues of directionality: Aa2, Bb2, Xx2, Nn2 are compared.

表3是表示空间关系特征的索引表。在表3中作为空间关系特征仅仅示例性地表示了连接关系、邻接关系、交叠关系、包含关系、包容关系,还可以包含其余特征,在此不一一列举。Table 3 is an index table representing spatial relationship features. In Table 3, as spatial relationship features, connection relationships, adjacency relationships, overlapping relationships, containment relationships, and containment relationships are only exemplified, and other features may also be included, which are not listed here.

表3table 3

空间关系特征Spatial relationship features 连接关系connection relationship 邻接关系Adjacency 交叠关系Overlapping relationship 重叠关系Overlapping relationship 包含关系containment relationship 包容关系Inclusive relationship 其余关系rest of the relationship 浏览器1browser 1 Aaa1Aaa1 Aaa2Aaa2 Aaa3Aaa3 Aaa4Aaa4 Aaa5Aaa5 Aaa6Aaa6 …..... 浏览器2browser 2 Bbb1Bbb1 Bbb2Bbb2 Bbb3Bbb3 Bbb4Bbb4 Bbb5Bbb5 Bbb6Bbb6 ……... Xxx1Xxx1 Xxx2Xxx2 Xxx3Xxx3 Xxx4Xxx4 Xxx5Xxx5 Bbb6Bbb6 浏览器NbrowserN Nnn1Nnn1 Nnn2Nnn2 Nnn3Nnn3 Nnn4Nnn4 Nnn5Nnn5 Nnn6Nnn6

如下述这样比较浏览器1~N的空间关系特征的数值:Compare the values of the spatial relationship features of browsers 1~N as follows:

对于连接关系的特征值:对Aaa1 、Bbb1、 Xxx1 、Nnn1进行比较;For the eigenvalues of the connection relationship: compare Aaa1, Bbb1, Xxx1, and Nnn1;

对于邻近关系的特征值:对Aaa2、 Bbb2 、Xxx2、 Nnn2进行比较;For the eigenvalues of the adjacent relationship: compare Aaa2, Bbb2, Xxx2, Nnn2;

……...

对于包容关系的特征值:对Aaa6、 Bbb6 、Xxx6 、Nnn6进行比较。For the eigenvalues of the containment relationship: Aaa6, Bbb6, Xxx6, Nnn6 are compared.

根据上述的表1~表3中的三个维度的特征值处理可以得到一张软件交互界面的主要显示要素。得到特征信息后,对每张图片的特征值进行汇总,并按照软件系统界面设计的所有交互图片建立一张图片编码索引表。According to the eigenvalue processing of the three dimensions in Table 1 to Table 3 above, the main display elements of a software interface can be obtained. After the characteristic information is obtained, the characteristic value of each picture is summarized, and a picture coding index table is established according to all interactive pictures designed on the interface of the software system.

图3是表示本发明的浏览器兼容性测试分析方法中基于图片编码索引表进行比对的流程图。Fig. 3 is a flow chart showing the comparison based on the picture coding index table in the browser compatibility testing and analysis method of the present invention.

在图片编码索引表中,包含的各交互界面以编号i表示,j表示所有存在的交互界面数量。指定一款支持的主流浏览器为比对基准,将所有交互界面在不同浏览器上的显示结果进行批量比对分析。具体比对过程如图3所示。In the picture coding index table, each included interactive interface is represented by number i, and j represents the number of all existing interactive interfaces. Designate a supported mainstream browser as the comparison benchmark, and perform batch comparison analysis on the display results of all interactive interfaces on different browsers. The specific comparison process is shown in Figure 3.

其中,图3中的“读取比对配置文件进行索引位图匹配”的具体过程如下所述进行。Wherein, the specific process of "reading and comparing configuration files and performing index bitmap matching" in FIG. 3 is performed as follows.

假设对于颜色特征中的一阶矩进行比较。在比对配置文件中对一阶矩设置了一个浮动接受区间,例如,在比对配置文件中预先设置了一阶矩数值浮动为10,即表示如果数值差为10以内的话该图片在两个浏览器之间的一阶矩相等:Assume that the comparison is made for the first moments in the color features. A floating acceptance interval is set for the first-order moment in the comparison configuration file. For example, the floating value of the first-order moment is set to 10 in the comparison configuration file, which means that if the value difference is within 10, the picture is in two First moment equality between browsers:

如在表1中,A1=100 B1=110,则经比较后认为A1=B1;For example, in Table 1, A1=100 B1=110, A1=B1 after comparison;

如在表1中,A1= 80 B1=120,则经比较后认为A1不等于B1。For example, in Table 1, A1= 80 B1=120, then A1 is not equal to B1 after comparison.

另外,在比对过程中可根据测试要求,对系统显示界面不是十分敏感的信息进行相似匹配,即在比对过程中摒弃该段位图中个别信息的匹配。In addition, during the comparison process, according to the test requirements, similar matching can be performed on information that is not very sensitive on the system display interface, that is, the matching of individual information in the segment bitmap is discarded during the comparison process.

例如,某张图片的连接关系,测试过程中列为非重要信息,可以不进行表3中的Aaa1、Bbb1、 Xxx1、 Nnn1的比较,即摒弃该段位图中个别信息的匹配。For example, the connection relationship of a certain picture is listed as non-important information during the test, and the comparison of Aaa1, Bbb1, Xxx1, and Nnn1 in Table 3 may not be performed, that is, the matching of individual information in the segment bitmap is discarded.

以上,对于本发明的浏览器兼容性测试分析方法进行了说明。下面对于本发明的浏览器兼容性测试分析系统进行简单说明。Above, the browser compatibility test and analysis method of the present invention has been described. The browser compatibility test and analysis system of the present invention will be briefly described below.

本发明的浏览器兼容性测试分析系包括:显示方式相同的不同的浏览器,用于显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;图片编码索引表建立模块,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表;图片比对模块,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及测试报告生成模块,根据比对结果生成测试报告。The browser compatibility test analysis system of the present invention includes: different browsers with the same display mode, used to display the interactive interface of the software system to be tested and save screenshots for the display of each interactive interface; a picture coding index table building module, Perform image preprocessing on the saved screenshots to extract multi-dimensional feature values, and build a picture coding index table for each screenshot according to the extracted multi-dimensional feature values; the picture comparison module compares each interaction according to the picture coding index table. The display results of the interface on different browsers are compared in batches and the comparison results are generated; and the test report generation module generates a test report according to the comparison results.

其中,所述显示方式相同的不同的浏览器是指选择尺寸和分辨率相同的多个显示器并安装不同的浏览器或者在一台显示器上安装不同的浏览器,同时剔除浏览器的第三方插件。Wherein, the different browsers with the same display mode refers to selecting multiple monitors with the same size and resolution and installing different browsers or installing different browsers on one monitor, and removing third-party plug-ins of browsers at the same time .

根据本发明的浏览器兼容性测试分析方法及浏览器兼容性测试分析系统,能够对待测软件系统在不同浏览器上的显示结果进行批量自动分析比对,并能够通过配置文件灵活控制比对的信息位图摒弃不敏感的比对信息,比对完成后将比对结果自动生成测试报告。因此,利用本发明,能够提高浏览器兼容性测试的效率和准确性。According to the browser compatibility test and analysis method and browser compatibility test and analysis system of the present invention, the display results of the software system to be tested on different browsers can be automatically analyzed and compared in batches, and the comparison can be flexibly controlled through configuration files The information bitmap discards insensitive comparison information, and after the comparison is completed, the comparison results will automatically generate a test report. Therefore, using the present invention, the efficiency and accuracy of browser compatibility testing can be improved.

以上例子主要说明了本发明的浏览器兼容性测试分析方法及浏览器兼容性测试分析系统。尽管只对其中一些本发明的具体实施方式进行了描述,但是本领域普通技术人员应当了解,本发明可以在不偏离其主旨与范围内以许多其他的形式实施。因此,所展示的例子与实施方式被视为示意性的而非限制性的,在不脱离如所附各权利要求所定义的本发明精神及范围的情况下,本发明可能涵盖各种的修改与替换。The above examples mainly illustrate the browser compatibility test analysis method and browser compatibility test analysis system of the present invention. Although only some specific embodiments of the present invention have been described, those skilled in the art should understand that the present invention can be implemented in many other forms without departing from the spirit and scope thereof. The examples and embodiments shown are therefore to be regarded as illustrative and not restrictive, and the invention may cover various modifications without departing from the spirit and scope of the invention as defined in the appended claims with replace.

Claims (7)

1.一种浏览器兼容性测试分析方法,其特征在于,包括下述步骤:1. A browser compatibility test analysis method, characterized in that, comprises the following steps: 待测系统显示步骤,以相同的显示方式在不同的浏览器上使得显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;The display step of the system to be tested is to display the interactive interface of the software system to be tested on different browsers in the same display mode and save the screenshot for the display of each interactive interface; 图片编码索引表建立步骤,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表;The step of establishing a picture coding index table is to perform picture preprocessing on the saved screenshots to extract multi-dimensional feature values, and to establish a picture coding index table for each screenshot according to the extracted multi-dimensional feature values; 图片比对步骤,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果,其中,通过配置文件灵活控制比对的信息位图,摒弃不敏感的比对信息,其中,以规定的浏览器为比对基准,按照图片编号查找图片编码索引表,对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及In the picture comparison step, according to the picture coding index table, the display results of each interactive interface on different browsers are compared in batches and the comparison results are generated, wherein, the information bitmap of the comparison is flexibly controlled through the configuration file, and different information bits are discarded. Sensitive comparison information, wherein, using the specified browser as the comparison benchmark, look up the picture coding index table according to the picture number, perform batch comparison of the display results of each interactive interface on different browsers, and generate a comparison result; and 测试报告生成步骤,根据比对结果生成测试报告,A test report generating step, generating a test report according to the comparison results, 在所述待测系统显示步骤中,所述以相同的显示方式在不同的浏览器上是指,选择尺寸和分辨率相同的多个显示器并安装不同的浏览器或者在一台显示器上安装不同的浏览器,同时剔除浏览器的第三方插件。In the step of displaying the system under test, using the same display method on different browsers refers to selecting multiple monitors with the same size and resolution and installing different browsers or installing different browsers on one monitor. browsers, while removing third-party plug-ins from browsers. 2.如权利要求1所述的浏览器兼容性测试分析方法,其特征在于,2. browser compatibility test analysis method as claimed in claim 1, is characterized in that, 在所述图片编码索引表建立步骤中,对保存的截图进行图片预处理,以提取颜色特征值、纹理特征值、空间关系特征值,并且根据这三个特征值对每张截图建立图片编码索引表。In the step of establishing the picture encoding index table, perform image preprocessing on the saved screenshots to extract color feature values, texture feature values, and spatial relationship feature values, and establish a picture encoding index for each screenshot according to these three feature values surface. 3.如权利要求2所述的浏览器兼容性测试分析方法,其特征在于,3. browser compatibility test analysis method as claimed in claim 2, is characterized in that, 所述图片编码索引表建立步骤包括下述子步骤:The step of establishing the picture coding index table includes the following sub-steps: 颜色特征提取步骤,对保存的截图进行图片预处理以提取表示颜色分布的颜色矩;The color feature extraction step is to carry out image preprocessing to the saved screenshot to extract the color moment representing the color distribution; 纹理特征提取步骤,对保存的截图中包含多个像素点进行统计计算,以获取表述图像的表面性质的纹理特征;以及A texture feature extraction step, performing statistical calculations on multiple pixels contained in the saved screenshot, so as to obtain texture features representing the surface properties of the image; and 空间关系特征提取步骤,对保存的截图中的多个目标之间的相互的空间位置或相对方向关系进行计算得到空间关系特征。The spatial relationship feature extraction step is to calculate the mutual spatial position or relative direction relationship between multiple objects in the saved screenshot to obtain the spatial relationship feature. 4.如权利要求3所述的浏览器兼容性测试分析方法,其特征在于,4. browser compatibility test analysis method as claimed in claim 3, is characterized in that, 所述颜色矩包括下述特征:一阶矩、二阶矩、三阶矩,The color moments include the following features: first-order moments, second-order moments, third-order moments, 所述纹理特征包括下述特征:纹理粗细度、方向性,The texture features include the following features: texture thickness, directionality, 所述空间关系特征包括下述特征:连接关系、邻接关系、交叠关系、重叠关系、包含关系、包容关系。The spatial relationship features include the following features: connection relationship, adjacency relationship, overlap relationship, overlap relationship, containment relationship, containment relationship. 5.如权利要求1所述的浏览器兼容性测试分析方法,其特征在于,5. browser compatibility test analysis method as claimed in claim 1, is characterized in that, 在所述图片比对步骤中,进行图片特征索引位匹配。In the picture comparing step, picture feature index bits are matched. 6.如权利要求5所述的浏览器兼容性测试分析方法,其特征在于,6. browser compatibility test analysis method as claimed in claim 5, is characterized in that, 所述图片特征索引位匹配包括下述子步骤:The picture feature index bit matching includes the following sub-steps: 对于两个浏览器的某个特征值,读取预先设定的规定数值范围;For a characteristic value of the two browsers, read the preset specified value range; 判断两个浏览器的某个特征值之差是否在该预设的规定数值范围内;Determine whether the difference between a characteristic value of the two browsers is within the preset specified value range; 如果在该规定范围内,则判断为两个浏览器的该特征值为相同,否则,判断为两个浏览器的该特征值为不相同。If it is within the specified range, it is determined that the characteristic values of the two browsers are the same; otherwise, it is determined that the characteristic values of the two browsers are different. 7.一种浏览器兼容性测试分析系统,其特征在于,包括:7. A browser compatibility test and analysis system, characterized in that it comprises: 显示方式相同的不同的浏览器,用于显示待测试的软件系统的交互界面并且对每个交互界面的显示保存截图;Different browsers with the same display mode are used to display the interactive interface of the software system to be tested and save screenshots of the display of each interactive interface; 图片编码索引表建立模块,对保存的截图进行图片预处理以提取多纬度的特征值,根据提取的多维度的特征值,对每张截图建立图片编码索引表;The image encoding index table building module is used to perform image preprocessing on the saved screenshots to extract multi-dimensional feature values, and establish an image encoding index table for each screenshot according to the extracted multi-dimensional feature values; 图片比对模块,根据所述图片编码索引表对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果,其中,通过配置文件灵活控制比对的信息位图,摒弃不敏感的比对信息,其中,以规定的浏览器为比对基准,按照图片编号查找图片编码索引表,对各交互界面在不同浏览器上的显示结果进行批量比对并生成比对结果;以及The picture comparison module performs batch comparison on the display results of each interactive interface on different browsers according to the picture coding index table and generates the comparison results, wherein, the information bitmap of the comparison is flexibly controlled through the configuration file, and the different information bitmaps are discarded. Sensitive comparison information, wherein, using the specified browser as the comparison benchmark, look up the picture coding index table according to the picture number, perform batch comparison of the display results of each interactive interface on different browsers, and generate a comparison result; and 测试报告生成模块,根据比对结果生成测试报告,The test report generation module generates a test report according to the comparison results, 所述显示方式相同的不同的浏览器是指,选择尺寸和分辨率相同的多个显示器并安装不同的浏览器或者在一台显示器上安装不同的浏览器,同时剔除浏览器的第三方插件。The different browsers with the same display mode refer to selecting multiple monitors with the same size and resolution and installing different browsers or installing different browsers on one monitor, while removing third-party plug-ins of the browsers.
CN201310697428.1A 2013-12-18 2013-12-18 Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system Active CN104731694B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310697428.1A CN104731694B (en) 2013-12-18 2013-12-18 Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310697428.1A CN104731694B (en) 2013-12-18 2013-12-18 Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system

Publications (2)

Publication Number Publication Date
CN104731694A CN104731694A (en) 2015-06-24
CN104731694B true CN104731694B (en) 2018-03-27

Family

ID=53455604

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310697428.1A Active CN104731694B (en) 2013-12-18 2013-12-18 Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system

Country Status (1)

Country Link
CN (1) CN104731694B (en)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106326091B (en) * 2015-06-24 2020-12-11 深圳市腾讯计算机系统有限公司 Method and system for detecting browser webpage compatibility
CN106776267A (en) * 2015-11-25 2017-05-31 富士通株式会社 Web application compatibility test method and web application compatibility test equipment
CN106411633A (en) * 2016-08-23 2017-02-15 国家电网公司 Web application compatibility testing method based on openstack and system thereof
CN108614762A (en) * 2016-12-09 2018-10-02 武汉斗鱼网络科技有限公司 A kind of browser testing method and device
CN107894948A (en) * 2016-12-30 2018-04-10 上海亿账通互联网科技有限公司 The method and device of resolution ratio compatibility test
CN106886491A (en) * 2017-01-17 2017-06-23 博彦科技股份有限公司 Webpage compatibility test method and device
CN107239405B (en) * 2017-08-03 2020-04-28 四川长虹电器股份有限公司 Automatic testing method based on Android multi-browser kernel
CN107885662A (en) * 2017-11-09 2018-04-06 郑州云海信息技术有限公司 A kind of method of testing based on more browser multi-version compatibility sex chromosome mosaicisms
CN108549601A (en) * 2018-04-02 2018-09-18 郑州云海信息技术有限公司 A kind of more browser compatibility automated testing methods
CN109471801A (en) * 2018-10-31 2019-03-15 北京微播视界科技有限公司 Image processing method, device, electronic equipment and computer readable storage medium
CN110704669A (en) * 2019-10-16 2020-01-17 紫光云技术有限公司 Resolution compatibility test image analysis method
CN112540925B (en) * 2020-12-16 2024-12-10 贝壳技术有限公司 New feature compatibility detection system and method, electronic device and readable storage medium

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101211355B (en) * 2006-12-30 2010-05-19 中国科学院计算技术研究所 A Method of Image Query Based on Clustering
US8996988B2 (en) * 2009-10-19 2015-03-31 Browsera, LLC Automated application compatibility testing
CN102546273A (en) * 2010-12-15 2012-07-04 上海杉达学院 Test system and test method for WAP (wireless application protocol) website
CN102323880A (en) * 2011-06-30 2012-01-18 中兴通讯股份有限公司 Mobile phone application interface development method and terminal based on browser parsing mode
CN103136094B (en) * 2011-11-25 2016-08-03 阿里巴巴集团控股有限公司 A kind of page method of testing and device
US9037965B2 (en) * 2012-02-13 2015-05-19 Accenture Global Services Limited Browser and operating system compatibility

Also Published As

Publication number Publication date
CN104731694A (en) 2015-06-24

Similar Documents

Publication Publication Date Title
CN104731694B (en) Browser compatibility method for testing and analyzing and browser compatibility detecting and analysing system
US10599399B2 (en) Mobile user interface design testing tool
EP3563243B1 (en) Determining application test results using screenshot metadata
US11010883B2 (en) Automated analysis of petrographic thin section images using advanced machine learning techniques
US10216727B2 (en) Visually differentiating strings for testing
JP2018523195A5 (en)
CN105824748B (en) For determining the method and system of test case efficiency
JP2017010476A (en) Similarity determination device, similarity determination method and similarity determination program
Afthanorhan et al. A parametric approach using z-test for comparing 2 means to multi-group analysis in partial least square structural equation modeling (PLS-SEM)
CN107193747B (en) Code testing method and device and computer equipment
WO2019019356A1 (en) Application program test method and apparatus, computer device and storage medium
US9529489B2 (en) Method and apparatus of testing a computer program
US10372849B2 (en) Performing and communicating sheet metal simulations employing a combination of factors
CN107798675A (en) The detection method and device of smear in display image
US20190149878A1 (en) Determining and correlating visual context on a user device with user behavior using digital content on the user device
JP2017068293A (en) Test db data generation method and device
US20160112285A1 (en) Apparatus and method for detecting abnormal connection
US10152674B2 (en) Accelerated decision tree execution
WO2019090691A1 (en) Monkey testing method and terminal
US20130346055A1 (en) Modeling and cooperative simulation of systems with interdependent discrete and continuous elements
US10157049B2 (en) Static analysis with input reduction
CN113032251B (en) Method, device and storage medium for determining service quality of application program
CN105574816A (en) Method and device for eliminating grid shadows of X-ray images as well as X-ray machine updating package
US9483818B2 (en) Bleed-through detection method and bleed-through detection apparatus
US20170192485A1 (en) Providing a power optimized design for a device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant