[CalendarServer-changes] [6344] CalendarServer/branches/users/glyph/more-deferreds-6/twistedcaldav/ test/util.py
source_changes at macosforge.org
source_changes at macosforge.org
Wed Sep 22 21:39:15 PDT 2010
Revision: 6344
http://trac.macosforge.org/projects/calendarserver/changeset/6344
Author: glyph at apple.com
Date: 2010-09-22 21:39:15 -0700 (Wed, 22 Sep 2010)
Log Message:
-----------
yield to commit
Modified Paths:
--------------
CalendarServer/branches/users/glyph/more-deferreds-6/twistedcaldav/test/util.py
Modified: CalendarServer/branches/users/glyph/more-deferreds-6/twistedcaldav/test/util.py
===================================================================
--- CalendarServer/branches/users/glyph/more-deferreds-6/twistedcaldav/test/util.py 2010-09-23 04:37:18 UTC (rev 6343)
+++ CalendarServer/branches/users/glyph/more-deferreds-6/twistedcaldav/test/util.py 2010-09-23 04:39:15 UTC (rev 6344)
@@ -352,7 +352,7 @@
"""
if not self.committed:
self.committed = True
- self.site.resource._associatedTransaction.commit()
+ return self.site.resource._associatedTransaction.commit()
@inlineCallbacks
@@ -361,7 +361,7 @@
Refresh the user resource positioned at the root of this site, to give
it a new transaction.
"""
- self.noRenderCommit()
+ yield self.noRenderCommit()
if request is None:
request = norequest()
users = yield self.homeProvisioner.getChild("users")
@@ -387,7 +387,7 @@
Override C{send} in order to refresh the 'user' resource each time, to
get a new transaction to associate with the calendar home.
"""
- self.noRenderCommit()
+ yield self.noRenderCommit()
yield self._refreshRoot(request)
result = (yield super(HomeTestCase, self).send(request))
self.committed = True
@@ -424,12 +424,13 @@
self.directoryService, "/addressbooks/",
_newStore
)
-
+
+ @inlineCallbacks
def _defer(user):
# Commit the transaction
- self.site.resource._associatedTransaction.commit()
+ yield self.site.resource._associatedTransaction.commit()
self.docroot = user._newStoreHome._path.path
-
+
return self._refreshRoot().addCallback(_defer)
@inlineCallbacks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20100922/dd56e17e/attachment-0001.html>
More information about the calendarserver-changes
mailing list