Exemple #1
0
        public void TestGetAllParentOrganization()
        {
            using (UnitOfWork unitwork = new UnitOfWork(store, dbContextFactory))
            {
                IRepository<Organization, Guid> organRepository = new Repository<Organization, Guid>(store);
                OrganizationService organizationService = new OrganizationService();

                ICollection<Organization> allParents = organizationService.GetAllParentOrganizations(organRepository.Query(s => s.Name=="企畫課").First().Id);
                Assert.AreEqual(2, allParents.Count);
            }
        }