From 1c0ffc5caf783fce6d3d89bdef1de97cea310a33 Mon Sep 17 00:00:00 2001
From: holger krekel <holger@merlinux.eu>
Date: Mon, 28 Sep 2015 14:02:30 +0200
Subject: [PATCH] seems like pypy's callable builtin calls __getattr__ so we do
 the check later.

---
 _pytest/python.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/_pytest/python.py b/_pytest/python.py
index 6548cdbf5..0ad18b3ef 100644
--- a/_pytest/python.py
+++ b/_pytest/python.py
@@ -1918,14 +1918,14 @@ class FixtureManager:
         autousenames = []
         for name in dir(holderobj):
             obj = getattr(holderobj, name, None)
-            if not callable(obj):
-                continue
             # fixture functions have a pytest_funcarg__ prefix (pre-2.3 style)
             # or are "@pytest.fixture" marked
             marker = getfixturemarker(obj)
             if marker is None:
                 if not name.startswith(self._argprefix):
                     continue
+                if not callable(obj):
+                    continue
                 marker = defaultfuncargprefixmarker
                 name = name[len(self._argprefix):]
             elif not isinstance(marker, FixtureFunctionMarker):