{"id":297816,"date":"2020-01-28T15:00:18","date_gmt":"2020-01-28T15:00:18","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=297816"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=297816","title":{"rendered":"\u041f\u0440\u043e\u0441\u0442\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0434\u043b\u044f \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u043e\u043d\u043d\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f \u043d\u0430 Java + Selenium Webdriver + aShot"},"content":{"rendered":"\n<div class=\"post__text post__text-html\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/485710\/\">\u0417\u0434\u0440\u0430\u0432\u0441\u0442\u0432\u0443\u0439\u0442\u0435.<\/p>\n<p>  \u042f \u0443\u0436\u0435 \u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043b <a href=\"https:\/\/habr.com\/ru\/post\/461553\/\">\u0441\u0442\u0430\u0442\u044c\u044e<\/a> \u043e \u0441\u0432\u043e\u0435\u043c \u043e\u043f\u044b\u0442\u0435 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u043e\u043d\u043d\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>  \u0421 \u0442\u0435\u0445 \u043f\u043e\u0440 \u043f\u0440\u043e\u0435\u043a\u0442 \u0431\u044b\u043b \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0434\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u043d \u2014 \u0438\u0437\u043c\u0435\u043d\u0438\u043b\u0430\u0441\u044c \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430, \u0441\u0442\u0430\u043b\u043e \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u043f\u0440\u043e\u0449\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0438 \u043d\u0430\u0447\u0430\u0442\u044c \u043f\u0438\u0441\u0430\u0442\u044c \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u044b, \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043b\u0443\u0447\u0448\u0435\u043d \u043e\u0442\u0447\u0435\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2x\/wd\/w4\/2xwdw479i_x2gosf6whoc4jvcho.png\"><\/p>\n<p>  <b><a href=\"https:\/\/github.com\/predewill\/VisualRegressionFramework\">VisualRegressionFramework<\/a><\/b> \u2014 \u044d\u0442\u043e \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432. \u0414\u043b\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u044f \u0440\u0430\u0431\u043e\u0442\u0430\u044e \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u043e\u043a\u043e\u043b\u043e 50 \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u043e\u0432 (\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b + \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b). <br \/>  <a name=\"habracut\"><\/a><br \/>  \u0417\u0430\u043f\u0443\u0441\u043a\u0430\u044e \u0442\u0435\u0441\u0442\u044b \u043f\u043e\u0441\u043b\u0435 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u0439 \u0432 \u0432\u0435\u0440\u0441\u0442\u043a\u0435. \u041b\u044e\u0431\u044b\u0435 \u0438\u0437\u043c\u0435\u043d\u0435\u043d\u0438\u044f \u0432\u0438\u0434\u043d\u044b \u0441\u0440\u0430\u0437\u0443, \u0442\u043e \u0435\u0441\u0442\u044c \u0442\u0430\u043a\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u043a\u0430\u043a &quot;<i>\u043f\u043e\u043c\u0435\u043d\u044f\u043b\u0438 \u0432\u0435\u0440\u0441\u0442\u043a\u0443 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u043d\u0430 \u043e\u0434\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435, \u0430 \u043d\u0430 \u0434\u0440\u0443\u0433\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0432\u0441\u0435 \u0441\u043b\u043e\u043c\u0430\u043b\u043e\u0441\u044c<\/i>&quot; \u0434\u0430\u0432\u043d\u043e \u0440\u0435\u0448\u0435\u043d\u044b. <\/p>\n<p>  \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u044b\u0435 \u0442\u0435\u0445\u043d\u043e\u043b\u043e\u0433\u0438\u0438 \u2014 Java, TestNG, Maven, Selenium Webdriver, aShot (\u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0430 \u0434\u043b\u044f \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u044f \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0439). <\/p>\n<h3>\u0412\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438:<\/h3>\n<p>  <\/p>\n<ul>\n<li>\u0421\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446<\/li>\n<li>\u0421\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u0441\u0442\u0440\u0430\u043d\u0438\u0446 + \u0438\u0433\u043d\u043e\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u044b\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 (\u0434\u0438\u043d\u0430\u043c\u0438\u0447\u043d\u044b\u0439 \u043a\u043e\u043d\u0442\u0435\u043d\u0442 \u0438 \u0442.\u043f.)<\/li>\n<li>\u0421\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432<\/li>\n<li>\u0411\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u044b \u2014 \u043c\u043e\u0436\u043d\u043e \u0441\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0438\u043b\u0438 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u043f\u0440\u0438 \u0440\u0430\u0437\u043d\u043e\u0439 \u0448\u0438\u0440\u0438\u043d\u0435. \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u0442\u0441\u044f 3 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430 \u2014 1920px, 768px, 360px <\/li>\n<li>\u0410\u0432\u0442\u043e\u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u0445 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 <\/li>\n<li>\u041c\u043e\u0436\u043d\u043e \u043f\u0438\u0441\u0430\u0442\u044c \u0442\u0435\u0441\u0442\u044b \u043a\u0430\u043a \u043e\u0431\u044b\u0447\u043d\u044b\u0435 \u0444\u0443\u043d\u043a\u0446\u0438\u043e\u043d\u0430\u043b\u044c\u043d\u044b\u0435 \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u044b, \u043a\u0430\u043a\u0438\u0445 \u043b\u0438\u0431\u043e \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0439 \u043d\u0435\u0442 \u2014 \u044d\u0442\u043e \u0432\u0430\u0436\u043d\u043e \u0442\u0430\u043a \u043a\u0430\u043a \u0438\u043d\u043e\u0433\u0434\u0430 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u043f\u0440\u043e\u0438\u0437\u0432\u0435\u0441\u0442\u0438 \u043a\u0430\u043a\u0438\u0435-\u0442\u043e \u0441\u043b\u043e\u0436\u043d\u044b\u0435 \u0434\u0435\u0439\u0441\u0442\u0432\u0438\u044f, \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u043c \u043a\u0430\u043a \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442. <\/li>\n<\/ul>\n<p>  <\/p>\n<h3>\u041e\u0442\u0447\u0451\u0442<\/h3>\n<p>  \u041e\u0442\u0447\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0438\u0442 \u0442\u0430\u043a:<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2x\/wd\/w4\/2xwdw479i_x2gosf6whoc4jvcho.png\"><\/p>\n<p>  \u0412 \u043b\u0435\u0432\u043e\u043c \u0441\u0430\u0439\u0434\u0431\u0430\u0440\u0435 \u0443\u043a\u0430\u0437\u0430\u043d \u0441\u043f\u0438\u0441\u043e\u043a \u0442\u0435\u0441\u0442\u043e\u0432, \u043b\u043e\u0433 \u0441 \u043e\u0448\u0438\u0431\u043a\u0430\u043c\u0438, \u0431\u0440\u0430\u0443\u0437\u0435\u0440 \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u043b\u0438\u0441\u044c \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u044b.<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u043c\u043e\u0436\u043d\u043e \u043f\u0435\u0440\u0435\u043a\u043b\u044e\u0447\u0430\u0442\u044c\u0441\u044f \u043c\u0435\u0436\u0434\u0443 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430\u043c\u0438 \u0438 \u0443\u0432\u0435\u043b\u0438\u0447\u0438\u0442\u044c \u043b\u044e\u0431\u043e\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435, \u043a\u043b\u0438\u043a\u043d\u0443\u0432 \u043d\u0430 \u043d\u0435\u0433\u043e. <\/p>\n<h3>\u0421\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430<\/h3>\n<p>  <b>src\/config\/visual.properties<\/b> \u2014 \u0437\u0434\u0435\u0441\u044c \u0443\u043a\u0430\u0437\u0430\u043d\u044b \u0432\u0441\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438<\/p>\n<ul>\n<li>breakpoints \u2014 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u044b, \u0448\u0438\u0440\u0438\u043d\u0430 \u0441\u0430\u0439\u0442\u0430 \u043f\u0440\u0438 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0431\u0443\u0434\u0435\u0442 \u0441\u0434\u0435\u043b\u0430\u043d \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442<\/li>\n<li><b>allowableDiffSize<\/b> \u2014 \u0434\u043e\u043f\u0443\u0441\u0442\u0438\u043c\u043e\u0435 \u0440\u0430\u0441\u0445\u043e\u0436\u0434\u0435\u043d\u0438\u0435 \u043c\u0435\u0436\u0434\u0443 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u043c \u0438 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u043c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u043c \u0432 \u043f\u0438\u043a\u0441\u0435\u043b\u044f\u0445 <\/li>\n<li>\u043f\u0443\u0442\u0438 \u043a \u043f\u0430\u043f\u043a\u0430\u043c \u0441\u043e \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u0430\u043c\u0438 <\/li>\n<li>\u043f\u0443\u0442\u0438 \u043a \u0448\u0430\u0431\u043b\u043e\u043d\u0443 \u0434\u043b\u044f \u043e\u0442\u0447\u0435\u0442\u0430, \u043a \u0441\u0430\u043c\u043e\u043c\u0443 \u043e\u0442\u0447\u0435\u0442\u0443 \u0438 \u043a \u0444\u0430\u0439\u043b\u0443 \u0441 \u043b\u043e\u0433\u043e\u043c \u043e\u0448\u0438\u0431\u043e\u043a <\/li>\n<\/ul>\n<p>  <b>report\/REPORT.html<\/b> \u2014 \u043e\u0442\u0447\u0435\u0442<\/p>\n<p>  <b>screenshots<\/b><\/p>\n<ul>\n<li><b>actual<\/b> \u2014 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0441\u043e\u0437\u0434\u0430\u044e\u0442\u0441\u044f \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0442\u0435\u0441\u0442\u0430 <\/li>\n<li><b>expected<\/b> \u2014 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u0435 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b, \u0435\u0441\u043b\u0438 \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u0445 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432 \u043d\u0435\u0442, \u043e\u043d\u0438 \u0431\u0443\u0434\u0443\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u044b \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0447\u0435\u0441\u043a\u0438 \u043f\u0440\u0438 \u043f\u0435\u0440\u0432\u043e\u043c \u0437\u0430\u043f\u0443\u0441\u043a\u0435 \u0442\u0435\u0441\u0442\u0430 <\/li>\n<li><b>diff<\/b> \u2014 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435 \u043d\u0430 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u043a\u0440\u0430\u0441\u043d\u044b\u043c \u0446\u0432\u0435\u0442\u043e\u043c \u0432\u044b\u0434\u0435\u043b\u0435\u043d\u044b \u043d\u0435\u0441\u043e\u0432\u043f\u0430\u0434\u0430\u044e\u0449\u0438\u0435 \u043e\u0431\u043b\u0430\u0441\u0442\u0438 <\/li>\n<li><b>gif<\/b> \u2014 \u0433\u0438\u0444\u043a\u0438 \u0441\u043e\u0437\u0434\u0430\u043d\u043d\u044b\u0435 \u0438\u0437 actual, expected \u0438 diff \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0439 <\/li>\n<\/ul>\n<p>  <b>src\/main\/framework<\/b> \u2014 \u043a\u043b\u0430\u0441\u0441\u044b \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u0430 \u2014 \u0433\u0435\u043d\u0435\u0440\u0430\u0442\u043e\u0440 \u043e\u0442\u0447\u0435\u0442\u0430, \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u043e\u0432, \u0433\u0438\u0444\u043e\u043a \u0438 \u0442.\u0434. <\/p>\n<p>  <b>src\/main\/app<\/b> \u2014 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u0438\u043c\u0435\u0440 page object \u0430\u0440\u0445\u0438\u0442\u0435\u043a\u0442\u0443\u0440\u044b, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u043d\u0435 \u043e\u0431\u044f\u0437\u0430\u0442\u0435\u043b\u044c\u043d\u043e, \u043c\u043e\u0436\u043d\u043e \u0443\u0434\u0430\u043b\u0438\u0442\u044c.<\/p>\n<p>  <b>src\/test\/resources\/testng.xml<\/b> \u2014 \u0441\u044e\u0434\u0430 \u043d\u0443\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c \u043d\u043e\u0432\u044b\u0435 \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b, \u043c\u0435\u0436\u0434\u0443 A_BeforeAllTests \u0438 A_AfterAllTests<\/p>\n<p>  <b>src\/test\/java<\/b><\/p>\n<ul>\n<li>A_BaseTest \u2014 \u0431\u0430\u0437\u043e\u0432\u044b\u0439 \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0439 \u043a\u043b\u0430\u0441\u0441 \u043e\u0442 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0434\u043e\u043b\u0436\u043d\u044b \u043d\u0430\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u0442\u044c\u0441\u044f \u0432\u0441\u0435 \u043d\u043e\u0432\u044b\u0435 \u0442\u0435\u0441\u0442\u043e\u0432\u044b\u0435 \u043a\u043b\u0430\u0441\u0441\u044b <\/li>\n<li>A_BeforeAllTests \u2014 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 \u043f\u0435\u0440\u0435\u0434 \u0442\u0435\u0441\u0442\u0430\u043c\u0438 <\/li>\n<li>A_AfterAllTests \u2014 \u0433\u0435\u043d\u0435\u0440\u0430\u0446\u0438\u044f \u043e\u0442\u0447\u0435\u0442\u0430 \u043f\u043e\u0441\u043b\u0435 \u0442\u0435\u0441\u0442\u043e\u0432 <\/li>\n<li>A_ErrorsLogListener \u2014 \u0437\u0430\u043f\u0438\u0441\u044c \u043e\u0448\u0438\u0431\u043e\u043a \u0432 \u043b\u043e\u0433 <\/li>\n<li>StaticGuestTest \u2014 \u043f\u0440\u0438\u043c\u0435\u0440 \u0442\u0435\u0441\u0442\u043e\u0432\u043e\u0433\u043e \u043a\u043b\u0430\u0441\u0441\u0430 <\/li>\n<\/ul>\n<p>  <b>\u041a\u043b\u0430\u0441\u0441\u044b \u0437\u0430\u043f\u0443\u0441\u043a\u0430\u044e\u0442\u0441\u044f \u0432 \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u043d\u043e\u043c \u043f\u043e\u0440\u044f\u0434\u043a\u0435:<\/b><\/p>\n<ol>\n<li>\u0441\u043d\u0430\u0447\u0430\u043b\u0430 \u0438\u0434\u0435\u0442 \u0438\u043d\u0438\u0446\u0438\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u044f \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043a \u0438 \u0431\u0440\u0430\u0443\u0437\u0435\u0440\u0430 \u2014 \u043a\u043b\u0430\u0441\u0441 <b>A_BeforeAllTests<\/b> <\/li>\n<li>\u0437\u0430\u0442\u0435\u043c \u043e\u0442\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u044e\u0442 \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u044b<\/li>\n<li>\u0438 \u0432 \u043a\u043e\u043d\u0446\u0435 \u0433\u0435\u043d\u0435\u0440\u0438\u0440\u0443\u0435\u0442\u0441\u044f \u043e\u0442\u0447\u0435\u0442 \u2014 \u043a\u043b\u0430\u0441\u0441 <b>A_AfterAllTests<\/b><\/li>\n<\/ol>\n<p>  <\/p>\n<h3>\u041a\u0430\u043a \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 \u0444\u0440\u0435\u0439\u043c\u0432\u043e\u0440\u043a\u043e\u043c<\/h3>\n<p>  <b>\u041f\u0440\u0438\u043c\u0435\u0440 \u0442\u0435\u0441\u0442\u0430<\/b><\/p>\n<pre><code class=\"java\">    @Test     public void indexPage()     {         app.open();         app.preparePageForScreenshot();         Comparer.comparePages(&quot;index_page&quot;);     }<\/code><\/pre>\n<p>  \u0412 \u0432\u044b\u0448\u0435\u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0442\u043a\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430, \u0437\u0430\u0442\u0435\u043c \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0433\u043e\u0442\u043e\u0432\u0438\u0442\u0441\u044f \u043a \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u0443, \u043f\u043e\u0441\u043b\u0435 \u0447\u0435\u0433\u043e \u0441\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u043e\u0436\u0438\u0434\u0430\u0435\u043c\u044b\u0439 \u0438 \u0430\u043a\u0442\u0443\u0430\u043b\u044c\u043d\u044b\u0439 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b. \u0421\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u043e\u0437\u0434\u0430\u044e\u0442\u0441\u044f \u0438 \u0441\u0440\u0430\u0432\u043d\u0438\u0432\u0430\u044e\u0442\u0441\u044f \u0432\u043e \u0432\u0441\u0435\u0445 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430\u0445. <\/p>\n<p>  <b>\u0417\u0430\u0447\u0435\u043c \u043d\u0443\u0436\u043d\u0430 \u0444\u0443\u043d\u043a\u0446\u0438\u044f preparePageForScreenshot()<\/b>:<\/p>\n<p>  \u041f\u043e \u0443\u043c\u043e\u043b\u0447\u0430\u043d\u0438\u044e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0440\u043e\u043a\u0440\u0443\u0447\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432\u043d\u0438\u0437, \u0430 \u0437\u0430\u0442\u0435\u043c \u043d\u0430\u0432\u0435\u0440\u0445 \u0447\u0435\u0440\u0435\u0437 js + \u0435\u0441\u0442\u044c \u0441\u0435\u043a\u0443\u043d\u0434\u043d\u0430\u044f \u0437\u0430\u0434\u0435\u0440\u0436\u043a\u0430. \u042d\u0442\u043e \u043d\u0443\u0436\u043d\u043e \u0447\u0442\u043e\u0431\u044b \u0443\u0441\u043f\u0435\u043b\u0438 \u0437\u0430\u0433\u0440\u0443\u0437\u0438\u0442\u044c\u0441\u044f \u0432\u0441\u0435 \u0438\u0437\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f, \u0441\u0442\u0438\u043b\u0438 \u0438 \u0442.\u043f.<\/p>\n<p>  \u0422\u0430\u043a\u0436\u0435 \u0432 \u044d\u0442\u043e\u0439 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u043c\u043e\u0436\u043d\u043e \u0441\u043a\u0440\u044b\u0442\u044c \u043d\u0435\u043d\u0443\u0436\u043d\u044b\u0435 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u0438\u043d\u0430\u043c\u0438\u0447\u0435\u0441\u043a\u0438\u0439 \u0431\u043b\u043e\u043a \u0441 \u0440\u0435\u043a\u043b\u0430\u043c\u043e\u0439. \u042f \u0432 \u0441\u0432\u043e\u0435\u043c \u043f\u0440\u043e\u0435\u043a\u0442\u0435 \u0441\u043a\u0440\u044b\u0432\u0430\u044e \u0444\u0443\u0442\u0435\u0440, \u0445\u0435\u0434\u0435\u0440 \u0438 \u0441\u0430\u0439\u0434\u0431\u0430\u0440, \u0442\u0430\u043a \u043a\u0430\u043a \u043e\u043d\u0438 \u043e\u0434\u0438\u043d\u0430\u043a\u043e\u0432\u044b\u0435 \u043d\u0430 \u0432\u0441\u0435\u0445 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430\u0445. \u0411\u0435\u0437 \u044d\u0442\u0438\u0445 \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u043e\u0432 \u0442\u0435\u0441\u0442\u044b \u043e\u0442\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u044e\u0442 \u0431\u044b\u0441\u0442\u0440\u0435\u0435 \u0438 \u043f\u0440\u043e\u0432\u0435\u0440\u044f\u0442\u044c \u043e\u0442\u0447\u0435\u0442 \u043f\u0440\u043e\u0449\u0435. <\/p>\n<p>  <b>\u0421\u0442\u0440\u0430\u043d\u0438\u0446\u044b<\/b><\/p>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432\u043e \u0432\u0441\u0435\u0445 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430\u0445:<\/p>\n<pre><code class=\"java\">Comparer.comparePages(&quot;test_name&quot;);<\/code><\/pre>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0432\u043e \u0432\u0441\u0435\u0445 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430\u0445 + \u0441\u043a\u0440\u044b\u0442\u044c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b:<\/p>\n<pre><code class=\"java\">Comparer.comparePages(&quot;test_name&quot;, new String[]{&quot;css_locator_1&quot;, &quot;css_locator_2&quot;});<\/code><\/pre>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0435:<\/p>\n<pre><code class=\"java\">Comparer.comparePagesWithBreakpoint(&quot;test_name&quot;, &quot;1920&quot;);<\/code><\/pre>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0435 + \u0441\u043a\u0440\u044b\u0442\u044c \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b:<\/p>\n<pre><code class=\"java\">Comparer.comparePagesWithBreakpoint(&quot;test_name&quot;, &quot;1920&quot;,  new String[]{&quot;css_locator_1&quot;, &quot;css_locator_2&quot;});<\/code><\/pre>\n<p>  <b>\u042d\u043b\u0435\u043c\u0435\u043d\u0442\u044b<\/b><\/p>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0432\u043e \u0432\u0441\u0435\u0445 \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0430\u0445:<\/p>\n<pre><code class=\"java\">Comparer.compareElements(&quot;test_name&quot;, &quot;css_locator&quot;);<\/code><\/pre>\n<p>  \u0421\u0440\u0430\u0432\u043d\u0438\u0442\u044c \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u044b \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u0433\u043e \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u0430 \u0442\u043e\u043b\u044c\u043a\u043e \u0432 \u0443\u043a\u0430\u0437\u0430\u043d\u043d\u043e\u043c \u0431\u0440\u0435\u0439\u043a\u043f\u043e\u0438\u043d\u0442\u0435:<\/p>\n<pre><code class=\"java\">Comparer.compareElementsWithBreakpoint(&quot;test_name&quot;, &quot;1920&quot;, &quot;css_locator&quot;);<\/code><\/pre>\n<p>  <a href=\"https:\/\/github.com\/predewill\/VisualRegressionFramework\"><b>\u0421\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u0440\u0435\u043f\u043e\u0437\u0438\u0442\u043e\u0440\u0438\u0439 \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/b><\/a><\/p>\n<h3>\u0422\u0435\u043a\u0443\u0449\u0438\u0435 \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b<\/h3>\n<p>  <\/p>\n<ul>\n<li>\u0412 \u043a\u043e\u043d\u0435\u0446 \u0441\u043a\u0440\u0438\u043d\u0448\u043e\u0442\u0430 \u043c\u043e\u0436\u0435\u0442 \u0434\u043e\u0431\u0430\u0432\u043b\u044f\u0442\u044c\u0441\u044f \u0447\u0435\u0440\u043d\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c, \u0441\u0442\u0430\u043b\u043a\u0438\u0432\u0430\u043b\u0441\u044f \u0441 \u044d\u0442\u0438\u043c \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u0434\u0430\u0432\u043d\u043e. \u041f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0438\u0441\u0447\u0435\u0437\u043b\u0430 \u043a\u043e\u0433\u0434\u0430 \u044f \u0441\u0442\u0430\u043b \u0441\u043a\u0440\u044b\u0432\u0430\u0442\u044c \u0444\u0443\u0442\u0435\u0440. \u042d\u0442\u043e \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0431\u0438\u0431\u043b\u0438\u043e\u0442\u0435\u043a\u0438 aShot \u2014 <a href=\"https:\/\/github.com\/pazone\/ashot\/issues\/169\">https:\/\/github.com\/pazone\/ashot\/issues\/169<\/a> <\/li>\n<li>\u0410\u0432\u0442\u043e\u0442\u0435\u0441\u0442 \u043c\u043e\u0436\u0435\u0442 \u043d\u0435 \u043f\u0440\u043e\u0445\u043e\u0434\u0438\u0442\u044c \u0438\u0437-\u0437\u0430 \u0440\u0430\u0437\u043d\u0438\u0446\u044b \u0432 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u043e \u043f\u0438\u043a\u0441\u0435\u043b\u0435\u0439. \u041f\u0440\u043e\u0431\u043b\u0435\u043c\u0430 \u0440\u0435\u0448\u0430\u0435\u0442\u0441\u044f \u0443\u0432\u0435\u043b\u0438\u0447\u0435\u043d\u0438\u0435\u043c \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f <b>TestConfig.allowableDiffSize<\/b>. <\/li>\n<\/ul>\n<\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"https:\/\/habr.com\/ru\/post\/485710\/\"> https:\/\/habr.com\/ru\/post\/485710\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"\n<div class=\"post__text post__text-html\" id=\"post-content-body\" data-io-article-url=\"https:\/\/habr.com\/ru\/post\/485710\/\">\u0417\u0434\u0440\u0430\u0432\u0441\u0442\u0432\u0443\u0439\u0442\u0435.<\/p>\n<p>  \u042f \u0443\u0436\u0435 \u043f\u0443\u0431\u043b\u0438\u043a\u043e\u0432\u0430\u043b <a href=\"https:\/\/habr.com\/ru\/post\/461553\/\">\u0441\u0442\u0430\u0442\u044c\u044e<\/a> \u043e \u0441\u0432\u043e\u0435\u043c \u043e\u043f\u044b\u0442\u0435 \u0430\u0432\u0442\u043e\u043c\u0430\u0442\u0438\u0437\u0430\u0446\u0438\u0438 \u0432\u0438\u0437\u0443\u0430\u043b\u044c\u043d\u043e\u0433\u043e \u0440\u0435\u0433\u0440\u0435\u0441\u0441\u0438\u043e\u043d\u043d\u043e\u0433\u043e \u0442\u0435\u0441\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.<\/p>\n<p>  \u0421 \u0442\u0435\u0445 \u043f\u043e\u0440 \u043f\u0440\u043e\u0435\u043a\u0442 \u0431\u044b\u043b \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e\u0435 \u0434\u043e\u0440\u0430\u0431\u043e\u0442\u0430\u043d \u2014 \u0438\u0437\u043c\u0435\u043d\u0438\u043b\u0430\u0441\u044c \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430, \u0441\u0442\u0430\u043b\u043e \u0433\u043e\u0440\u0430\u0437\u0434\u043e \u043f\u0440\u043e\u0449\u0435 \u043d\u0430\u0441\u0442\u0440\u043e\u0438\u0442\u044c \u043f\u0440\u043e\u0435\u043a\u0442 \u0438 \u043d\u0430\u0447\u0430\u0442\u044c \u043f\u0438\u0441\u0430\u0442\u044c \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u044b, \u0437\u043d\u0430\u0447\u0438\u0442\u0435\u043b\u044c\u043d\u043e \u0443\u043b\u0443\u0447\u0448\u0435\u043d \u043e\u0442\u0447\u0435\u0442.<\/p>\n<p>  <img decoding=\"async\" src=\"https:\/\/habrastorage.org\/webt\/2x\/wd\/w4\/2xwdw479i_x2gosf6whoc4jvcho.png\"><\/p>\n<p>  <b><a href=\"https:\/\/github.com\/predewill\/VisualRegressionFramework\">VisualRegressionFramework<\/a><\/b> \u2014 \u044d\u0442\u043e \u0434\u043e\u0432\u043e\u043b\u044c\u043d\u043e \u043f\u0440\u043e\u0441\u0442\u043e\u0435 \u0440\u0435\u0448\u0435\u043d\u0438\u0435 \u0434\u043b\u044f \u043d\u0435\u0431\u043e\u043b\u044c\u0448\u0438\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u043e\u0432. \u0414\u043b\u044f \u043f\u0440\u043e\u0435\u043a\u0442\u0430 \u0441 \u043a\u043e\u0442\u043e\u0440\u044b\u043c \u044f \u0440\u0430\u0431\u043e\u0442\u0430\u044e \u043d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u043e\u043a\u043e\u043b\u043e 50 \u0430\u0432\u0442\u043e\u0442\u0435\u0441\u0442\u043e\u0432 (\u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b + \u044d\u043b\u0435\u043c\u0435\u043d\u0442\u044b).   <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-297816","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/297816","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=297816"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/297816\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=297816"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=297816"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=297816"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}