Exemplo n.º 1
0
        public void uniqueAreaNameTest()
        {
            Restaurant r = new Restaurant {
                Name = "BeanScene"
            };

            try
            {
                Area a1 = r.AddArea("MainFloor");
                Area a2 = r.AddArea("MainFloor");
            }
            catch (BusinessRuleException b)
            {
                StringAssert.Contains(b.Message, r.uniqueAreaName);
                return;
            }
            Assert.Fail("No exception was thrown.");
        }