Commit Graph

12 Commits

Author SHA1 Message Date
Walter Dörwald 536120e34d Merged revisions 71984 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r71984 | walter.doerwald | 2009-04-26 22:51:44 +0200 (So, 26 Apr 2009) | 2 lines

  Use test.test_support.EnvironmentVarGuard where tests change environment vars.
........
2009-04-26 21:04:55 +00:00
Amaury Forgeot d'Arc 9b69ed9d67 In test_site, correctly escape backslashes in path names.
This allows the test to pass when the username begins with a lowercase 't'...
2008-06-19 21:17:12 +00:00
Neal Norwitz 40388cc330 Fix "refleak" by restoring the tearDown method removed by accident (AFAICT)
in r62788.
2008-05-14 06:47:56 +00:00
Christian Heimes af748c3ab8 Implemented PEP 370 2008-05-06 22:41:46 +00:00
Christian Heimes c5f05e45cf Patch #2167 from calvin: Remove unused imports 2008-02-23 17:40:11 +00:00
Michael W. Hudson ff52286d4a Fix test_site to not call open('...', 'wU'), as that now raises an error.
Is anyone running the test suite regularly at the moment?
2005-05-27 14:58:06 +00:00
Tim Peters 182b5aca27 Whitespace normalization, via reindent.py. 2004-07-18 06:16:08 +00:00
Brett Cannon ee86a66dd8 Fixes a bug in testing code handling .pth files that did not restore the original
module that is removed for testing "import" lines.  Originally deleted the
entry from sys.modules and then just let other code that needed it to import it
again.  Problem with this solution is that it lead to code that had already
imported the module in question to have their own reference to a new copy of
the module in question that new code couldn't reach.  This lead to a failure in
test_strptime since it monkey-patched the 'time' module it had a reference to
while _strptime had its own reference to another copy of 'time' from being
imported by test___all__ that it was using for a calculation.

Also moved the testing code out of the PthFile class and into the actual test
class.  This was to stop using 'assert' which is useless with a -O execution.
2004-07-13 07:12:25 +00:00
Brett Cannon 64a8470246 Restructure testing of .pth files. Move previous functions into a class and
create a testing method that can be called to make sure that the handling of
the .pth file was correct.
2004-07-10 02:10:45 +00:00
Raymond Hettinger ebd95222bf * Silence a test failure that resulted when test_site was run by
regrtest.py after it ran test_frozen.  This test was really only
  designed to be run immediately after startup.  Afterwards, other
  modules could be loaded when had not been fixed-up by site.py
  Took the chicken way out and only tested those modules known to
  be imported by site.py.

* Normalized whitespace.
2004-06-27 03:02:18 +00:00
Brett Cannon 6ccc9a99df Removed test_sitepackages test. Skip discovered that it only passed if Python
had already been installed previously.
2004-06-08 18:25:48 +00:00
Brett Cannon 0096e262ff Refactored site.py into functions. Also moved over to using sets.
New regression test suite.
2004-06-05 01:12:51 +00:00