From adebe7052eeace48bcc687e1dc6e5a4f0c0c5781 Mon Sep 17 00:00:00 2001
From: diosmosis <benakamoorthi@fastmail.fm>
Date: Fri, 4 Jul 2014 17:55:50 -0700
Subject: [PATCH] Remove automatic detection of overflow from screenshot
 testing captureSelector method.

---
 tests/lib/screenshot-testing/support/page-renderer.js | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/tests/lib/screenshot-testing/support/page-renderer.js b/tests/lib/screenshot-testing/support/page-renderer.js
index a6a4da3e6b..960879b655 100644
--- a/tests/lib/screenshot-testing/support/page-renderer.js
+++ b/tests/lib/screenshot-testing/support/page-renderer.js
@@ -249,11 +249,7 @@ PageRenderer.prototype.capture = function (outputPath, callback, selector) {
             if (element && element.length) {
                 var clipRect = {bottom: null, height: null, left: null, right: null, top: null, width: null};
 
-                var children = element.find('*:visible').filter(function () {
-                    return $(this).css('position') == 'absolute';
-                });
-
-                element.add(children).each(function (index, node) {
+                element.each(function (index, node) {
                     var rect = node.getBoundingClientRect();
 
                     if (isInvalidBoundingRect(rect)) {
-- 
GitLab