Esempio n. 1
0
        public void TestRecycle()
        {
            Pool <TestClass> pool = new Pool <TestClass>();
            TestClass        x    = new TestClass();

            Assert.IsFalse(x.Recycled);
            pool.Redeem(x);
            Assert.IsTrue(x.Recycled);
        }
Esempio n. 2
0
        public void TestGetRecycled()
        {
            Pool <TestClass> pool = new Pool <TestClass>();

            pool.Redeem(new TestClass());

            TestClass test = pool.Get();

            Assert.IsTrue(test.Recycled);
        }
Esempio n. 3
0
        public void TestRedeem()
        {
            Pool <TestClass> pool = new Pool <TestClass>();

            pool.Redeem(new TestClass());
        }