ToBoolean() public method

Extracts a Boolean from an AtomicBoolean instance.
public ToBoolean ( ) : bool
return bool
Example #1
0
        public void Static_ToBoolean_Should_Return_False()
        {
            var b = new AtomicBoolean(false);

            AtomicBoolean.ToBoolean(b).Should().BeFalse();
        }
Example #2
0
        public void Static_ToBoolean_Should_Throw_On_Null()
        {
            Action action = () => AtomicBoolean.ToBoolean(null);

            action.ShouldThrow <InvalidCastException>();
        }
Example #3
0
        public void ToBoolean_Should_Return_False()
        {
            var b = new AtomicBoolean(false);

            b.ToBoolean().Should().BeFalse();
        }
Example #4
0
        public void Static_ToBoolean_Should_Return_True()
        {
            var b = new AtomicBoolean(true);

            AtomicBoolean.ToBoolean(b).Should().BeTrue();
        }
Example #5
0
        public void ToBoolean_Should_Return_True()
        {
            var b = new AtomicBoolean(true);

            b.ToBoolean().Should().BeTrue();
        }
 public void ToBoolean_Should_Return_True()
 {
     var b = new AtomicBoolean(true);
     b.ToBoolean().Should().BeTrue();
 }
 public void ToBoolean_Should_Return_False()
 {
     var b = new AtomicBoolean(false);
     b.ToBoolean().Should().BeFalse();
 }