Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Steur <thomas.steur@googlemail.com>2014-05-28 01:36:56 +0400
committerThomas Steur <thomas.steur@googlemail.com>2014-05-28 01:36:56 +0400
commit8ad283ef152e6b125f0685c641e11d45967e472f (patch)
treef0b70456118e3b699201418ce3629ca6593774e6 /tests/README.screenshots.md
parentb2dc389d4ce722cb499b87f2f607a68342a62e48 (diff)
added possibility to compare against a previously captured screenshot if using selector
Diffstat (limited to 'tests/README.screenshots.md')
-rw-r--r--tests/README.screenshots.md9
1 files changed, 8 insertions, 1 deletions
diff --git a/tests/README.screenshots.md b/tests/README.screenshots.md
index b0189fe343..39648b1435 100644
--- a/tests/README.screenshots.md
+++ b/tests/README.screenshots.md
@@ -143,7 +143,14 @@ If you want to compare only parts (all content within an element / selector) of
page.load(url);
}, done);
});
-
+
+If you want to compare a screenshot against an already existing expected screenshot and capture a selector you can do the following:
+
+ it("should load correctly", function (done) {
+ expect.screenshot("screenshot_name").to.be.captureSelector("processed_screenshot_name", "#content", function (page) {
+ page.load(url);
+ }, done);
+ });
### Manipulating Pages Before Capture