[py-svn] r48127 - in py/branch/reporter-merge/py/test: . terminal testing

fijal at codespeak.net fijal at codespeak.net
Sun Oct 28 12:56:43 CET 2007


Author: fijal
Date: Sun Oct 28 12:56:41 2007
New Revision: 48127

Removed:
   py/branch/reporter-merge/py/test/terminal/terminal.py
Modified:
   py/branch/reporter-merge/py/test/config.py
   py/branch/reporter-merge/py/test/session.py
   py/branch/reporter-merge/py/test/testing/test_config.py
   py/branch/reporter-merge/py/test/testing/test_session.py
Log:
Remove terminal session as it's no longer needed


Modified: py/branch/reporter-merge/py/test/config.py
==============================================================================
--- py/branch/reporter-merge/py/test/config.py	(original)
+++ py/branch/reporter-merge/py/test/config.py	Sun Oct 28 12:56:41 2007
@@ -159,7 +159,7 @@
 
     def _getsessionname(self):
         """ return default session name as determined from options. """
-        name = 'TerminalSession'
+        name = 'Session'
         if self.option.dist:
             name = 'RSession'
         else:
@@ -263,7 +263,7 @@
 
 # default import paths for sessions 
 
-TerminalSession = 'py.__.test.terminal.terminal'
+Session = 'py.__.test.session'
 RemoteTerminalSession = 'py.__.test.terminal.remote'
 RSession = 'py.__.test.rsession.rsession'
 LSession = 'py.__.test.rsession.rsession'

Modified: py/branch/reporter-merge/py/test/session.py
==============================================================================
--- py/branch/reporter-merge/py/test/session.py	(original)
+++ py/branch/reporter-merge/py/test/session.py	Sun Oct 28 12:56:41 2007
@@ -5,6 +5,15 @@
 from py.__.test import repevent
 from py.__.test.outcome import SerializableOutcome, ReprOutcome
 
+""" The session implementation - reporter version:
+
+* itemgen is responsible for iterating and telling reporter
+  about skipped and failed iterations (this is for collectors only),
+  this should be probably moved to session (for uniformity)
+* session gets items which needs to be executed one after another
+  and tells reporter about that
+"""
+
 def itemgen(session, colitems, reporter, keyword=None):
     stopitems = py.test.collect.Item # XXX should be generator here as well
     for next in colitems:

Deleted: /py/branch/reporter-merge/py/test/terminal/terminal.py
==============================================================================
--- /py/branch/reporter-merge/py/test/terminal/terminal.py	Sun Oct 28 12:56:41 2007
+++ (empty file)
@@ -1,12 +0,0 @@
-import py
-
-from time import time as now
-from py.__.test.terminal.out import getout 
-from py.__.test.representation import Presenter, getrelpath
-from py.__.test.outcome import Skipped, Passed, Failed
-import py.__.test.custompdb
-
-from py.__.test.session import Session
-
-class TerminalSession(Session): 
-    pass

Modified: py/branch/reporter-merge/py/test/testing/test_config.py
==============================================================================
--- py/branch/reporter-merge/py/test/testing/test_config.py	(original)
+++ py/branch/reporter-merge/py/test/testing/test_config.py	Sun Oct 28 12:56:41 2007
@@ -200,7 +200,7 @@
 
     def test_sessionname_default(self):
         config = py.test.config._reparse([self.tmpdir])
-        assert config._getsessionname() == 'TerminalSession'
+        assert config._getsessionname() == 'Session'
 
     def test_sessionname_dist(self):
         config = py.test.config._reparse([self.tmpdir, '--dist'])

Modified: py/branch/reporter-merge/py/test/testing/test_session.py
==============================================================================
--- py/branch/reporter-merge/py/test/testing/test_session.py	(original)
+++ py/branch/reporter-merge/py/test/testing/test_session.py	Sun Oct 28 12:56:41 2007
@@ -130,11 +130,11 @@
    
 class TestTerminalSession:
     def mainsession(self, *args):
-        from py.__.test.terminal.terminal import TerminalSession
+        from py.__.test.session import Session
         from py.__.test.terminal.out import getout
         config = py.test.config._reparse(list(args))
         all = []
-        session = TerminalSession(config, all.append)
+        session = Session(config, all.append)
         session.main()
         return session, all
 


More information about the py-svn mailing list