Exemplo n.º 1
0
 private void TestSizes()
 {
     Striped.Lock(100).Size
     .Should().BeGreaterOrEqualTo(100);
     Striped.Lock(256).Size
     .Should().Be(256);
 }
Exemplo n.º 2
0
 private void TestBasicInvariants()
 {
     AssertBasicInvariants(Striped.Lock(100));
     AssertBasicInvariants(Striped.Lock(256));
     AssertBasicInvariants(Striped.Semaphore(100, 1));
     AssertBasicInvariants(Striped.Semaphore(256, 1));
     AssertBasicInvariants(Striped.ReaderWriterLock(100));
     AssertBasicInvariants(Striped.ReaderWriterLock(256));
 }