public async Task ReleasingOneOfTwoReadLocksDoesNotReleaseWaitingWriteAndReadLocks()
        {
            var myLock = new AsyncReaderWriterLockSlim();

            await myLock.EnterReadLockAsync();

            await myLock.EnterReadLockAsync();

            var writeLockTask = myLock.TryEnterWriteLockAsync(500);
            var readLockTask  = myLock.TryEnterReadLockAsync(300);

            // When releasing one of the two read locks, the waiting write lock should not
            // be released, and also the waiting read lock should not be released because of
            // the waiting write lock.
            myLock.ExitReadLock();

            Assert.IsFalse(await readLockTask);
            Assert.IsFalse(await writeLockTask);
        }