[py-svn] r57172 - in py/branch/event/py/test2: . dist rep rep/testing testing

hpk at codespeak.net hpk at codespeak.net
Sun Aug 10 18:41:20 CEST 2008


Author: hpk
Date: Sun Aug 10 18:41:19 2008
New Revision: 57172

Modified:
   py/branch/event/py/test2/dist/hostmanage.py
   py/branch/event/py/test2/rep/rest.py
   py/branch/event/py/test2/rep/terminal.py
   py/branch/event/py/test2/rep/testing/test_rest.py
   py/branch/event/py/test2/rep/testing/test_terminal.py
   py/branch/event/py/test2/rep/web.py
   py/branch/event/py/test2/repevent.py
   py/branch/event/py/test2/testing/acceptance_test.py
Log:
rename HostGatewayReady back to original name


Modified: py/branch/event/py/test2/dist/hostmanage.py
==============================================================================
--- py/branch/event/py/test2/dist/hostmanage.py	(original)
+++ py/branch/event/py/test2/dist/hostmanage.py	Sun Aug 10 18:41:19 2008
@@ -133,7 +133,7 @@
         python = self.session.config.getvalue("dist_remotepython")
         for host in self.hosts:
             host.initgateway(python=python)
-            self.session.bus.notify(repevent.HostReady(host, self.roots))
+            self.session.bus.notify(repevent.HostGatewayReady(host, self.roots))
             host.gw.host = host
 
     def init_rsync(self):

Modified: py/branch/event/py/test2/rep/rest.py
==============================================================================
--- py/branch/event/py/test2/rep/rest.py	(original)
+++ py/branch/event/py/test2/rep/rest.py	Sun Aug 10 18:41:19 2008
@@ -66,7 +66,7 @@
     def report_ImmediateFailure(self, item):
         pass
 
-    def report_HostReady(self, item):
+    def report_HostGatewayReady(self, item):
         self.to_rsync[item.host] = len(item.roots)
 
     def report_ItemStart(self, event):

Modified: py/branch/event/py/test2/rep/terminal.py
==============================================================================
--- py/branch/event/py/test2/rep/terminal.py	(original)
+++ py/branch/event/py/test2/rep/terminal.py	Sun Aug 10 18:41:19 2008
@@ -34,8 +34,8 @@
         for line in str(ev.excinfo.getrepr()).split("\n"):
             self.write_line("InternalException: " + line)
 
-    def rep_HostReady(self, ev):
-        self.write_line("HostReady: %s" %(ev.host,))
+    def rep_HostGatewayReady(self, ev):
+        self.write_line("HostGatewayReady: %s" %(ev.host,))
 
     def rep_HostDown(self, ev):
         host = ev.host

Modified: py/branch/event/py/test2/rep/testing/test_rest.py
==============================================================================
--- py/branch/event/py/test2/rep/testing/test_rest.py	(original)
+++ py/branch/event/py/test2/rep/testing/test_rest.py	Sun Aug 10 18:41:19 2008
@@ -64,7 +64,7 @@
     def test_report_HostRSyncRootReady(self):
         h = Host('localhost')
         reporter.hosts_to_rsync = 1
-        reporter.report(repevent.HostReady(h, ["a"]))
+        reporter.report(repevent.HostGatewayReady(h, ["a"]))
         event = repevent.HostRSyncRootReady(h, "a")
         reporter.report(event)
         assert stdout.getvalue() == '::\n\n   localhost: READY\n\n'

Modified: py/branch/event/py/test2/rep/testing/test_terminal.py
==============================================================================
--- py/branch/event/py/test2/rep/testing/test_terminal.py	(original)
+++ py/branch/event/py/test2/rep/testing/test_terminal.py	Sun Aug 10 18:41:19 2008
@@ -77,9 +77,9 @@
         stringio = py.std.cStringIO.StringIO()
         host1 = Host("localhost")
         rep = TerminalReporter(modcol._config, file=stringio)
-        rep.processevent(repevent.HostReady(host1, None))
+        rep.processevent(repevent.HostGatewayReady(host1, None))
         s = popvalue(stringio)
-        assert s.find("HostReady") != -1
+        assert s.find("HostGatewayReady") != -1
         rep.processevent(repevent.HostDown(host1, "myerror"))
         s = popvalue(stringio)
         assert s.find("HostDown") != -1

Modified: py/branch/event/py/test2/rep/web.py
==============================================================================
--- py/branch/event/py/test2/rep/web.py	(original)
+++ py/branch/event/py/test2/rep/web.py	Sun Aug 10 18:41:19 2008
@@ -300,7 +300,7 @@
     def _host_ready(self, event):
         self.pending_events.put(event)
 
-    def report_HostReady(self, item):
+    def report_HostGatewayReady(self, item):
         self.to_rsync[item.host] = len(item.roots)
 
     def report_HostRSyncRootReady(self, item):

Modified: py/branch/event/py/test2/repevent.py
==============================================================================
--- py/branch/event/py/test2/repevent.py	(original)
+++ py/branch/event/py/test2/repevent.py	Sun Aug 10 18:41:19 2008
@@ -94,7 +94,7 @@
     def __init__(self, items):
         self.items = items
  
-class HostReady(BaseEvent):
+class HostGatewayReady(BaseEvent):
     def __init__(self, host, roots):
         self.host = host
         self.roots = roots

Modified: py/branch/event/py/test2/testing/acceptance_test.py
==============================================================================
--- py/branch/event/py/test2/testing/acceptance_test.py	(original)
+++ py/branch/event/py/test2/testing/acceptance_test.py	Sun Aug 10 18:41:19 2008
@@ -267,9 +267,9 @@
         )
         result = self.runpytest(p1, '-d')
         assert_lines_contain_lines(result.outlines, [
-            "HostReady*localhost*",
-            "HostReady*localhost*",
-            "HostReady*localhost*",
+            "HostGatewayReady*localhost*",
+            "HostGatewayReady*localhost*",
+            "HostGatewayReady*localhost*",
             "HostDown*localhost*TERMINATED*",
             "*1/3 passed + 1 skip*",
             "*failures: 2*",



More information about the pytest-commit mailing list