Author: Armin Rigo <[email protected]>
Branch:
Changeset: r92012:c88684d6f4c1
Date: 2017-08-01 12:43 +0200
http://bitbucket.org/pypy/pypy/changeset/c88684d6f4c1/
Log: Skip unreliable test when testing with either -A or with a pypy host
diff --git a/pypy/module/_vmprof/test/test__vmprof.py
b/pypy/module/_vmprof/test/test__vmprof.py
--- a/pypy/module/_vmprof/test/test__vmprof.py
+++ b/pypy/module/_vmprof/test/test__vmprof.py
@@ -1,3 +1,4 @@
+import sys
from rpython.tool.udir import udir
from pypy.tool.pytest.objspace import gettestobjspace
@@ -7,6 +8,8 @@
def setup_class(cls):
cls.w_tmpfilename = cls.space.wrap(str(udir.join('test__vmprof.1')))
cls.w_tmpfilename2 = cls.space.wrap(str(udir.join('test__vmprof.2')))
+ cls.w_plain = cls.space.wrap(not cls.runappdirect and
+ '__pypy__' not in sys.builtin_module_names)
def test_import_vmprof(self):
tmpfile = open(self.tmpfilename, 'wb')
@@ -117,6 +120,8 @@
assert _vmprof.get_profile_path() is None
def test_stop_sampling(self):
+ if not self.plain:
+ skip("unreliable test except on CPython without -A")
import os
import _vmprof
tmpfile = open(self.tmpfilename, 'wb')
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit