예제 #1
0
        public void CHANGE_ORGANIZATION()
        {
            OrganizationService service = null;

            try
            {
                Configure();
                service = new OrganizationService();
                service.Register(MockList[0]);
            }
            catch (Exception ex)
            {
                Assert.Fail(ex.Message);
            }

            try
            {
                service = new OrganizationService();
                var org = MockList[0];
                org.SetName("Organization Name Changed");
                service.Change(org);
            }
            catch (Exception ex)
            {
                service.Remove(MockList[0]);
                Assert.Fail(ex.Message);
            }

            var organization = service.FindById("1");

            service.Remove(MockList[0]);
            Assert.AreEqual(organization.Name, "Organization Name Changed");
        }