コード例 #1
0
        public void TestGetProductGamesFound()
        {
            ProductDistributor producer    = new ProductDistributor();
            Product            testProduct = ProductFlyweightFactory.MakeProduct();

            producer.AddProduct(testProduct);

            Assert.IsNotNull(producer.GetProduct(testProduct.Game.GetName()));
        }
コード例 #2
0
        public void TestGetProductNoGamesFound()
        {
            ProductDistributor producer = new ProductDistributor();

            Assert.IsNull(producer.GetProduct("Call of Duty"));
        }