Exemplo n.º 1
0
        public void Apply_IsObject_Test()
        {
            var obj    = CreateMockObject();
            var broken = new Broken();

            broken.Apply(obj);
            Assert.AreSame(broken, obj.Conditions[0]);
        }
Exemplo n.º 2
0
        public void Apply_NotAnObject_Test()
        {
            var entity = Mock.Of <IEntity>();
            var Broken = new Broken();

            Broken.Apply(entity);
            Assert.IsTrue(true); // If we made it here with exception then the test passed
        }
Exemplo n.º 3
0
        public void Apply_Character_WithExistingBrokenCondition_Test()
        {
            var obj = CreateMockObject();

            obj.Conditions.Add(new Broken());
            var broken = new Broken();

            broken.Apply(obj);
        }