… except for the refcount test which doesn't work (and makes no sense)
under PyPy as it has a non-reference count model).
doc: $(DOCHTML)/index.html
test:
- for ver in 2.4 2.5 2.6 2.7 3.0 3.1 3.2; do \
+ for ver in 2.4 2.5 2.6 2.7 3.0 3.1 3.2 3.3 3.4; do \
if type python$$ver >/dev/null; then \
echo Testing with python$$ver; \
- python$$ver ./setup.py test; \
+ python$$ver ./setup.py test -q; \
fi; \
done
+ @if type pypy >/dev/null; then \
+ echo Testing with pypy; \
+ pypy ./setup.py test -q; \
+ fi
+
clean:
rm -rf $(DOCHTML) $(DOCTREES)
import os
import tempfile
import sys
+import platform
import posix1e
from posix1e import *
def checkRef(self, obj):
"""Checks if a given obj has a 'sane' refcount"""
+ if platform.python_implementation() == "PyPy":
+ return
ref_cnt = sys.getrefcount(obj)
# FIXME: hardcoded value for the max ref count... but I've
# seen it overflow on bad reference counting, so it's better