Commits

holger krekel committed 319187f

adjustments and fixes to test run, distribution files. thanks thm.

Comments (0)

Files changed (8)

 Changes between 1.1.1 and 1.1.0
 =====================================
 
-- introduce automatic lookup of 'pytest11' entrypoints
-  via setuptools' pkg_resources.iter_entry_points
+- introduce automatic plugin registration via 'pytest11' 
+  entrypoints via setuptools' pkg_resources.iter_entry_points
 
 - fix py.test dist-testing to work with execnet >= 1.0.0b4 
 
   allow '%' in svn paths, make svnwc.update() default to interactive mode 
   like in 1.0.x and add svnwc.update(interactive=False) to inhibit interaction.
 
+- refine distributed tarball to contain test and no pyc files
+
 - try harder to have deprecation warnings for py.compat.* accesses
   report a correct location
 
 include setup.py
 include distribute_setup.py
 include LICENSE 
+include conftest.py 
 graft doc
 graft contrib
 graft bin 
+graft testing
 exclude *.orig 
 exclude *.rej 
 exclude .hginore
+exclude *.pyc
+recursive-exclude testing *.pyc *.orig *.rej *$py.class
+prune .pyc
 prune .svn 
 prune .hg 

doc/announce/release-1.1.1.txt

 
 This is a compatibility fixing release of pylib/py.test to work
 better with previous 1.0.x test code bases.  It also contains fixes
-and changes to work with `execnet>=1.0.0b4`_.  1.1.1 also introduces
+and changes to work with `execnet>=1.0.0`_ to provide distributed
+testing and looponfailing testing modes.  py-1.1.1 also introduces
 a new mechanism for registering plugins via setuptools. 
-Last but not least, documentation has been improved.
 
 What is pylib/py.test? 
 -----------------------
 
 holger (http://twitter.com/hpk42)
 
-.. _`execnet>=1.0.0b4`: http://codespeak.net/execnet
+.. _`execnet>=1.0.0`: http://codespeak.net/execnet
 
 Changes between 1.1.1 and 1.1.0
 =====================================
 
-- introduce automatic lookup of 'pytest11' entrypoints
-  via setuptools' pkg_resources.iter_entry_points
+- introduce automatic plugin registration via 'pytest11' 
+  entrypoints via setuptools' pkg_resources.iter_entry_points
 
 - fix py.test dist-testing to work with execnet >= 1.0.0b4 
 
   allow '%' in svn paths, make svnwc.update() default to interactive mode 
   like in 1.0.x and add svnwc.update(interactive=False) to inhibit interaction.
 
+- refine distributed tarball to contain test and no pyc files
+
 - try harder to have deprecation warnings for py.compat.* accesses
   report a correct location
-

doc/example/assertion/global_testmodule_config/conftest.py

 import py
+mydir = py.path.local(__file__).dirpath()
 
 def pytest_runtest_setup(item):
     if isinstance(item, py.test.collect.Function):
+        if not item.fspath.relto(mydir):
+            return
         mod = item.getparent(py.test.collect.Module).obj
         if hasattr(mod, 'hello'):
             py.builtin.print_("mod.hello", mod.hello)

py/plugin/pytest_pytester.py

         return self.runpybin("py.test", *args)
 
     def spawn_pytest(self, string, expect_timeout=10.0):
-        pexpect = py.test.importorskip("pexpect", "2.3")
+        pexpect = py.test.importorskip("pexpect", "2.4")
         basetemp = self.tmpdir.mkdir("pexpect")
         invoke = "%s %s" % self._getpybinargs("py.test")
         cmd = "%s --basetemp=%s %s" % (invoke, basetemp, string)

testing/path/test_svnauth.py

 import time
 import sys
 
+svnbin = py.path.local.sysfind('svn')
+
 def make_repo_auth(repo, userdata):
     """ write config to repo
     
 
 class pytest_funcarg__setup:
     def __init__(self, request):
+        if not svnbin:
+            py.test.skip("svn binary required")
         if not request.config.option.runslowtests:
             py.test.skip('use --runslowtests to run these tests')
 

testing/plugin/test_pytest_restdoc.py

         assert request.module.__name__ == __name__
         testdir.makepyfile(confrest=
             "from py.plugin.pytest_restdoc import Project")
+        # we scope our confrest file so that it doesn't
+        # conflict with another global confrest.py 
+        testdir.makepyfile(__init__="")
         for p in testdir.plugins:
             if p == globals():
                 break

testing/plugin/test_pytest_terminal.py

         p = testdir.makepyfile("import Errlkjqweqwe")
         result = testdir.runpytest("--collectonly", p)
         stderr = result.stderr.str().strip()
-        assert stderr.startswith("inserting into sys.path")
         assert result.ret == 1
         extra = result.stdout.fnmatch_lines(py.code.Source("""
             <Module '*.py'>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.