public void DisabledCount()
        {
            var pool = new PoolCollection <Target>();

            pool.Add(new Target());

            Assert.AreEqual(1, pool.DisabledCount);
        }
        public void Enabled()
        {
            var pool = new PoolCollection <Target>();

            pool.Add(new Target());
            pool.Enable();

            int count = pool.Enabled.Count();

            Assert.AreEqual(1, count);
        }
        public void IsDisabled()
        {
            var pool   = new PoolCollection <Target>();
            var target = new Target();

            pool.Add(target);

            bool result0 = pool.IsDisabled(target);

            Assert.True(result0);
        }
        public void Remove()
        {
            var pool   = new PoolCollection <Target>();
            var target = new Target();

            pool.Add(target);

            Target result0 = pool.Remove();

            Assert.NotNull(result0);
            Assert.AreSame(result0, target);
            Assert.AreEqual(0, pool.Count);
        }
        public void Contains()
        {
            var pool   = new PoolCollection <Target>();
            var target = new Target();

            pool.Add(target);

            bool result0 = pool.Contains(target);
            bool result1 = pool.Contains(null);

            Assert.True(result0);
            Assert.False(result1);
        }
        public void Disable()
        {
            var pool   = new PoolCollection <Target>();
            var target = new Target();

            pool.Add(target);
            pool.Enable();

            bool result0 = pool.Disable(target);

            Assert.True(result0);
            Assert.AreEqual(1, pool.Count);
            Assert.AreEqual(0, pool.EnabledCount);
            Assert.AreEqual(1, pool.DisabledCount);
        }
        public void DisableAll()
        {
            var pool = new PoolCollection <Target>();

            for (int i = 0; i < 5; i++)
            {
                pool.Add(new Target());
                pool.Enable();
            }

            Assert.AreEqual(5, pool.Count);
            Assert.AreEqual(5, pool.EnabledCount);
            Assert.AreEqual(0, pool.DisabledCount);

            pool.DisableAll();

            Assert.AreEqual(5, pool.Count);
            Assert.AreEqual(0, pool.EnabledCount);
            Assert.AreEqual(5, pool.DisabledCount);
        }