[pypy-dev] Re: Objects and types in the stdobjspace

Michael Hudson mwh at python.net
Tue Jun 10 13:30:30 MEST 2003


roccomoretti at netscape.net (Rocco Moretti) writes:

> holger krekel <hpk at trillke.net> wrote:
>
>>Btw, I don't like the duplicated testsupport.py files. I think Rocco already 
>>suggested to put one version into a fixed place which i agree too. 
>>pypy.test.support seems like a canonical place. 
>
> The one problem with that is if you are sitting 
> in /norwegian/blue/pypy/interpreter/test, and '/norwegian/blue/' isn't on 
> your PYTHONPATH, you choke on trying to import pypy.test.support. One of 
> the main reasons (that I see, at least) for testsupport is that by doing a 
> relative 'import testsupport', it automagically massages your PYTHONPATH 
> such that 'from pypy...' imports work. But I agree that it probably should 
> be pared down to a stub, and it looks like someone (mwh?) has already 
> started that by moving a bunch of code to testtools.py

Yes.  I'm not sure how much more can easily be taken out of the
testsupport files; some more, probably, but not a huge amount.

> My suggestion was to move all the other files for general test support 
> (unittest_w.py, testtools.py etc) to a single directory, to leave the main 
> directory and the interpreter directory relatively uncluttered.

This is probably goodness.  There is (or, at least, I have) a tendency
to just dump stuff in pypy/interpreter when there's no obviously
better place for it.

>>Filename completions
>>on "te<tab>" should result in "test_" :-) 
>
> Could we rename it 'support_tests.py'?

If you care sufficiently, be my guest.  I don't.

Cheers,
M.

-- 
  Darn!  I've only got 10 minutes left to get falling-down drunk!  I
  suppose I'll have to smoke crack instead now.
                     -- Tim Peters is checking things in on 2002-12-31



More information about the pypy-dev mailing list