From e681ffe43c9465566c75d92c627175a44a1d866f Mon Sep 17 00:00:00 2001 From: amit3200 Date: Wed, 25 Oct 2023 14:03:58 +0530 Subject: [PATCH] :bookmark: release-v2.0.1 --- README.md | 34 +++++++++++++++------------------- package.json | 2 +- 2 files changed, 16 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 5164d2b..751436a 100644 --- a/README.md +++ b/README.md @@ -142,26 +142,22 @@ const driver = new webdriver.Builder().usingServer('https://hub-cloud.browsersta - `driver` (**required**) - A Selenium driver instance - `name` (**required**) - The screenshot name; must be unique to each screenshot - `options` (**optional**) - There are various options supported by percyScreenshot to server further functionality. - - `freezeAnimation` - Boolean value by default it falls back to `false`, you can pass `true` and percy will freeze image based animations. + - `freezeAnimatedImage` - Boolean value by default it falls back to `false`, you can pass `true` and percy will freeze image based animations. + - `freezeImageBySelectors` - List of selectors. Images will be freezed which are passed using selectors. + - `freezeImageByXpaths` - List of xpaths. Images will be freezed which are passed using xpaths. - `percyCSS` - Custom CSS to be added to DOM before the screenshot being taken. Note: This gets removed once the screenshot is taken. - - `ignoreRegionXpaths` - elements in the DOM can be ignored using xpath - - `ignoreRegionSelectors` - elements in the DOM can be ignored using selectors. - - `ignoreRegionSeleniumElements` - elements can be ignored using selenium_elements. - - `customIgnoreRegions` - elements can be ignored using custom boundaries - - IgnoreRegion:- - - Description: This class represents a rectangular area on a screen that needs to be ignored for visual diff. - - - Constructor: - ``` - init(self, top, bottom, left, right) - ``` - - Parameters: - `top` (int): Top coordinate of the ignore region. - `bottom` (int): Bottom coordinate of the ignore region. - `left` (int): Left coordinate of the ignore region. - `right` (int): Right coordinate of the ignore region. - - Raises:ValueError: If top, bottom, left, or right is less than 0 or top is greater than or equal to bottom or left is greater than or equal to right. - - valid: Ignore region should be within the boundaries of the screen. + - `ignoreRegionXpaths` - List of xpaths. elements in the DOM can be ignored using xpath + - `ignoreRegionSelectors` - List of selectors. elements in the DOM can be ignored using selectors. + - `ignoreRegionSeleniumElements` - List of selenium web-element. elements can be ignored using selenium_elements. + - `customIgnoreRegions` - List of custom object. elements can be ignored using custom boundaries. Just passing a simple object for it like below. + - example: ```json{top: 10, right: 10, bottom: 120, left: 10}``` + - In above example it will draw rectangle of ignore region which will be 10px below from top and 120px above from bottom. 10px apart from left and right. + - `considerRegionXpaths` - List of xpaths. elements in the DOM can be considered for diffing and will be ignored by Intelli Ignore using xpaths. + - `considerRegionSelectors` - List of selectors. elements in the DOM can be considered for diffing and will be ignored by Intelli Ignore using selectors. + - `considerRegionSeleniumElements` - List of selenium web-element. elements can be considered for diffing and will be ignored by Intelli Ignore using selenium_elements. + - `customConsiderRegions` - List of custom object. elements can be considered for diffing and will be ignored by Intelli Ignore using custom boundaries + - example: ```json{top: 10, right: 10, bottom: 120, left: 10}``` + - In above example it will draw rectangle of ignore region which will be 10px below from top and 120px above from bottom. 10px apart from left and right. ### Creating Percy on automate build Note: Automate Percy Token starts with `auto` keyword. The command can be triggered using `exec` keyword. diff --git a/package.json b/package.json index 75f01c6..33af3d0 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@percy/selenium-webdriver", "description": "Selenium client library for visual testing with Percy", - "version": "2.0.1-beta.1", + "version": "2.0.1", "license": "MIT", "author": "Perceptual Inc.", "repository": "https://github.com/percy/percy-selenium-js",