Skip to content

Commit eba4db2

Browse files
author
Nils Langner
committed
Update readme.md
1 parent 76bfbc0 commit eba4db2

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

readme.md

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,21 @@
11
# VisualCeption
22
Visual regression tests integrated in [Codeception](http://codeception.com/).
33

4+
This moculde can be used to compare screenshots of a website element.
5+
6+
## How it works
7+
8+
VisualCeption uses a combination of the "make a screenshot" feature in webdriver, imagick and jquery to compare visual elements on a website. This comparison is done in four steps:
9+
10+
1. **Take a screenshot** of the full page using webdriver.
11+
2. **Calculate the position** and size of the selected element using jquery.
12+
3. **Crop the element** out of the full screenshot using imagick.
13+
4. **Compare the element** with an older version of the screenshot that has been proofed as valid using imagick. If no previous image exists the current image will be used fur future comparions. As an effect of this approach the test has to be **run twice** before it works.
14+
5. If the deviation is too high **throw an exception** that is caught by Codeception.
15+
416
## Documenation todo
5-
* run twice
617
* phantom css
718
* example image
8-
* license
9-
* how it works
1019

1120
## Requirements
1221

0 commit comments

Comments
 (0)