コード例 #1
0
        public void canDeleteARecipe()
        {
            // Setup
            Recipe r = new Recipe(1);

            rm.AddNew(r);
            rm.AddNew(r);
            // Pre-validation
            Assert.AreEqual(2, rm.GetCurrentNumOfRecipes());
            // Exercise
            rm.DeleteRecipe(0);
            // Verify
            Assert.AreEqual(1, rm.GetCurrentNumOfRecipes());
        }