public void AtomicInteger_Should_Implement_Reference_Equality()
        {
            var firstAtomic = new AtomicInteger(int.MaxValue);
            var secondAtomic = new AtomicInteger(int.MinValue);

            Assert.False(firstAtomic.Equals(secondAtomic));
            Assert.False(secondAtomic.Equals(firstAtomic));

            // self equality
            Assert.True(firstAtomic.Equals(firstAtomic));
            Assert.True(secondAtomic.Equals(secondAtomic));
        }
        public void AtomicInteger_Should_Implement_Reference_Equality()
        {
            var firstAtomic  = new AtomicInteger(int.MaxValue);
            var secondAtomic = new AtomicInteger(int.MinValue);

            Assert.False(firstAtomic.Equals(secondAtomic));
            Assert.False(secondAtomic.Equals(firstAtomic));

            // self equality
            Assert.True(firstAtomic.Equals(firstAtomic));
            Assert.True(secondAtomic.Equals(secondAtomic));
        }
        public void AtomicInteger_IEquatable_Of_Int_Should_Compare()
        {
            IEquatable<int> firstAtomic = new AtomicInteger(int.MaxValue);
            IEquatable<int> secondAtomic = new AtomicInteger(int.MinValue);

            Assert.False(firstAtomic.Equals(int.MinValue));
            Assert.False(secondAtomic.Equals(int.MaxValue));
        }
        public void AtomicInteger_IEquatable_Of_Int_Should_Compare()
        {
            IEquatable <int> firstAtomic  = new AtomicInteger(int.MaxValue);
            IEquatable <int> secondAtomic = new AtomicInteger(int.MinValue);

            Assert.False(firstAtomic.Equals(int.MinValue));
            Assert.False(secondAtomic.Equals(int.MaxValue));
        }
        public void Equals_Test()
        {
            AtomicInteger atomicInteger = 5;

            Assert.True(atomicInteger.Equals(5));
        }