Example #1
0
        public void ProviderSearchTest()
        {
            this.logics = new ServiceProviderQueryLogics();
            var test = this.logics.ServiceProviderQuery(new List <int> {
                57
            }, new List <int> {
                1, 2
            });

            this.repo = new ServiceProviderRepo();
            var result = this.repo.GetServiceProviders(new List <int> {
                57
            }, new List <int> {
                1, 25
            });
        }
Example #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="AppDataController"/> class.
 /// </summary>
 public AppDataController()
 {
     this.dataLogic            = new DataLogics();
     this.familiesLogic        = new FamiliesLogic();
     this.serviceProviderLogic = new ServiceProviderQueryLogics();
 }
Example #3
0
        public void MyTestInitialize()
        {
            this.target = new ServiceProviderQueryLogics();

            this.contact = new Contact
            {
                Email    = "*****@*****.**",
                ID       = 1,
                Website  = "www.test.org",
                Phone    = "9373608284",
                HelpLine = "9373608888"
            };
            this.state = new State {
                Abbreviation = "OH", CountryID = 1, FullName = "Ohio", ID = 1
            };

            this.location1 = new Location
            {
                City            = "testville 1",
                ContactID       = 1,
                Contact         = this.contact,
                ContactPersonID = 1,
                ID                = 1,
                Display           = true,
                Zip               = "45344",
                Street            = "Test way 1",
                State             = this.state,
                StateID           = this.state.ID,
                ProviderCoverages = new List <ProviderCoverage> {
                    new ProviderCoverage {
                        AreaID = 1, LocationID = 1
                    }
                }
            };
            this.location2 = new Location
            {
                City            = "testville 2",
                ContactID       = 2,
                Contact         = this.contact,
                ContactPersonID = 2,
                ID                = 2,
                Display           = true,
                Zip               = "45344",
                Street            = "Test way 2",
                State             = this.state,
                StateID           = this.state.ID,
                ProviderCoverages = new List <ProviderCoverage> {
                    new ProviderCoverage {
                        AreaID = 2, LocationID = 2
                    }
                }
            };

            this.locations = new List <Location> {
                this.location1, this.location2
            };

            this.websiteAddress1 = string.Format(
                "{0}, {1}, {2}, {3}",
                this.location1.Street,
                this.location1.City,
                this.location1.State.Abbreviation,
                this.location1.Zip);

            this.websiteAddress2 = string.Format(
                "{0}, {1}, {2}, {3}",
                this.location2.Street,
                this.location2.City,
                this.location2.State.Abbreviation,
                this.location2.Zip);

            var providerService11 = new ProviderService {
                ID = 1, ProviderID = 1, ServiceID = 1
            };
            var providerService12 = new ProviderService {
                ID = 2, ProviderID = 1, ServiceID = 2
            };
            var providerService13 = new ProviderService {
                ID = 3, ProviderID = 1, ServiceID = 3
            };

            var providerService21 = new ProviderService {
                ID = 1, ProviderID = 2, ServiceID = 1
            };
            var providerService22 = new ProviderService {
                ID = 2, ProviderID = 2, ServiceID = 2
            };
            var providerService23 = new ProviderService {
                ID = 3, ProviderID = 2, ServiceID = 3
            };

            this.providerServices1 = new List <ProviderService>
            {
                providerService11,
                providerService12,
                providerService13,
            };

            this.providerServices2 = new List <ProviderService>
            {
                providerService21,
                providerService22,
                providerService23
            };

            this.serviceProvider1 = new ServiceProvider
            {
                Description      = "Test description for test 1",
                ID               = 1,
                DisplayRank      = 1,
                ProviderName     = "Test 1",
                Locations        = this.locations,
                ProviderServices = this.providerServices1
            };
            this.serviceProvider2 = new ServiceProvider
            {
                Description      = "Test description for test 2",
                ID               = 2,
                DisplayRank      = 2,
                ProviderName     = "Test 2",
                Locations        = this.locations,
                ProviderServices = this.providerServices2
            };

            this.serviceProviderList = new List <ServiceProvider> {
                this.serviceProvider1, this.serviceProvider2
            };
        }