title: py.test running Python2 and Python3
body: <p>I have written a package (<a href="http://github.com/anntzer/parsedcmd">http://github.com/anntzer/parsedcmd</a>) that runs with both Python2 and Python3.  However, I had to write separate (py.test) unit tests for Python2 and Python3 (mainly because I want to test extra features of Python3, in particular keyword-only arguments), so I have a <code>test_py2.py</code> and a <code>test_py3.py</code> in a <code>test</code> subpackage.  Now, if I run, say <code>py.test2 mypkg</code>, <code>test_py2</code> passes, but <code>test_py3</code> fails with a <code>SyntaxError</code>.  Likewise, for <code>py.test3 mypkg</code>, <code>test_py3</code> passes but <code>test_py2</code> fails (I could make this one work though, it's just an issue of <code>StringIO</code> having moved to <code>io</code>).</p>
  
  <p>I can design the <code>test</code> subpackage so that <code>import mypkg.test</code> only imports the proper version of the tests, but apparently py.test doesn't care -- it just sees two files matching <code>test_*</code> and grabs all tests in both of them, ignoring what <code>__init__.py</code> tells him to import.</p>
  
  <p>So right now I have to do both <code>py.test2 mypkg/test/test_py2.py</code> and <code>py.test3 mypkg/test/test_py3.py</code>.  Is there a way to set up the whole thing so that <code>py.test2 mypkg</code> and <code>py.test3 mypkg</code> would "just work"?</p>
  
  <p>Thanks.</p>