diff options
author | Sean Quah <8349537+squahtx@users.noreply.github.com> | 2022-04-05 16:54:40 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-05 16:54:40 +0100 |
commit | 9c4c49991de7e0f176864029580bebc7e6849fb1 (patch) | |
tree | 4bbd1feaf7a3cfab1380dec3835b8b3773de1991 /tests/util | |
parent | Refactor and convert `Linearizer` to async (#12357) (diff) | |
download | synapse-9c4c49991de7e0f176864029580bebc7e6849fb1.tar.xz |
Update docstrings for `ReadWriteLock` tests (#12354)
Signed-off-by: Sean Quah <seanq@element.io>
Diffstat (limited to 'tests/util')
-rw-r--r-- | tests/util/test_rwlock.py | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/util/test_rwlock.py b/tests/util/test_rwlock.py index 0c84226197..5da04362a9 100644 --- a/tests/util/test_rwlock.py +++ b/tests/util/test_rwlock.py @@ -40,8 +40,8 @@ class ReadWriteLockTestCase(unittest.TestCase): Returns: A tuple of three `Deferred`s: - * A `Deferred` that resolves with `return_value` once the reader or writer - completes successfully. + * A cancellable `Deferred` for the entire read or write operation that + resolves with `return_value` on successful completion. * A `Deferred` that resolves once the reader or writer acquires the lock. * A `Deferred` that blocks the reader or writer. Must be resolved by the caller to allow the reader or writer to release the lock and complete. @@ -87,8 +87,8 @@ class ReadWriteLockTestCase(unittest.TestCase): Returns: A tuple of two `Deferred`s: - * A `Deferred` that resolves with `return_value` once the reader completes - successfully. + * A cancellable `Deferred` for the entire read operation that resolves with + `return_value` on successful completion. * A `Deferred` that resolves once the reader acquires the lock. """ d, acquired_d, unblock_d = self._start_reader_or_writer( @@ -106,8 +106,8 @@ class ReadWriteLockTestCase(unittest.TestCase): Returns: A tuple of two `Deferred`s: - * A `Deferred` that resolves with `return_value` once the writer completes - successfully. + * A cancellable `Deferred` for the entire write operation that resolves + with `return_value` on successful completion. * A `Deferred` that resolves once the writer acquires the lock. """ d, acquired_d, unblock_d = self._start_reader_or_writer( |