コード例 #1
0
        public void LockUnlockTest()
        {
            UnsafeLock _lock = new UnsafeLock();

            _lock.Lock();

            _lock.Unlock();
        }
コード例 #2
0
 public void Add()
 {
     _lock.Lock();
     Num++;
     _lock.Unlock();
 }
コード例 #3
0
        public void UnlockNoLockTest()
        {
            UnsafeLock _lock = new UnsafeLock();

            Assert.Catch <UnsafeLockException>(() => { _lock.Unlock(); });
        }