[CalendarServer-changes] [8177] CalendarServer/trunk/twext/web2/test/test_http.py

source_changes at macosforge.org source_changes at macosforge.org
Mon Oct 10 10:37:01 PDT 2011


Revision: 8177
          http://trac.macosforge.org/projects/calendarserver/changeset/8177
Author:   glyph at apple.com
Date:     2011-10-10 10:37:00 -0700 (Mon, 10 Oct 2011)
Log Message:
-----------
Propagate necessary environment variables in tests.

Modified Paths:
--------------
    CalendarServer/trunk/twext/web2/test/test_http.py

Modified: CalendarServer/trunk/twext/web2/test/test_http.py
===================================================================
--- CalendarServer/trunk/twext/web2/test/test_http.py	2011-10-10 17:24:57 UTC (rev 8176)
+++ CalendarServer/trunk/twext/web2/test/test_http.py	2011-10-10 17:37:00 UTC (rev 8177)
@@ -1,7 +1,7 @@
 
 from __future__ import nested_scopes
 
-import time, sys
+import time, sys, os
 
 from zope.interface import implements
 
@@ -1092,7 +1092,10 @@
     def testBasicWorkingness(self):
         args = ('-u', util.sibpath(__file__, "simple_client.py"), "basic",
                 str(self.port), self.type)
-        d = waitForDeferred(utils.getProcessOutputAndValue(sys.executable, args=args))
+        d = waitForDeferred(
+            utils.getProcessOutputAndValue(sys.executable, args=args,
+                                           env=os.environ)
+        )
         yield d; out,err,code = d.getResult()
 
         self.assertEquals(code, 0, "Error output:\n%s" % (err,))
@@ -1102,7 +1105,10 @@
     def testLingeringClose(self):
         args = ('-u', util.sibpath(__file__, "simple_client.py"),
                 "lingeringClose", str(self.port), self.type)
-        d = waitForDeferred(utils.getProcessOutputAndValue(sys.executable, args=args))
+        d = waitForDeferred(
+            utils.getProcessOutputAndValue(sys.executable, args=args,
+                                           env=os.environ)
+        )
         yield d; out,err,code = d.getResult()
         self.assertEquals(code, 0, "Error output:\n%s" % (err,))
         self.assertEquals(out, "HTTP/1.1 402 Payment Required\r\nContent-Length: 0\r\nConnection: close\r\n\r\n")
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20111010/2f48a1df/attachment-0001.html>


More information about the calendarserver-changes mailing list