[CalendarServer-changes] [10255] CalendarServer/branches/users/glyph/queue-locking-and-timing

source_changes at macosforge.org source_changes at macosforge.org
Fri Jan 4 16:39:16 PST 2013


Revision: 10255
          http://trac.calendarserver.org//changeset/10255
Author:   glyph at apple.com
Date:     2013-01-04 16:39:16 -0800 (Fri, 04 Jan 2013)
Log Message:
-----------
Failing test for release.

Modified Paths:
--------------
    CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/locking.py
    CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/test/test_locking.py

Property Changed:
----------------
    CalendarServer/branches/users/glyph/queue-locking-and-timing/

Modified: CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/locking.py
===================================================================
--- CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/locking.py	2013-01-05 00:39:14 UTC (rev 10254)
+++ CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/locking.py	2013-01-05 00:39:16 UTC (rev 10255)
@@ -98,7 +98,6 @@
         @return: A L{Deferred} that fires with L{None} when the lock has been
             unlocked.
         """
-        raise NotImplementedError()
 
 
 

Modified: CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/test/test_locking.py
===================================================================
--- CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/test/test_locking.py	2013-01-05 00:39:14 UTC (rev 10254)
+++ CalendarServer/branches/users/glyph/queue-locking-and-timing/twext/enterprise/test/test_locking.py	2013-01-05 00:39:16 UTC (rev 10255)
@@ -52,3 +52,14 @@
         rows = yield Select(From=LockSchema.NAMED_LOCK).on(txn)
         self.assertEquals(rows, [tuple([u"a test lock"])])
 
+
+    @inlineCallbacks
+    def test_release(self):
+        """
+        Releasing an acquired lock removes the row.
+        """
+        txn = self.pool.connection()
+        lck = yield NamedLock.acquire(txn, u"a test lock")
+        yield lck.release()
+        rows = yield Select(From=LockSchema.NAMED_LOCK).on(txn)
+        self.assertEquals(rows, [])
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20130104/96fa3297/attachment.html>


More information about the calendarserver-changes mailing list