Exemplo n.º 1
0
        public void CreatePOI()
        {
            var newPoi = new PointOfInterest
            {
                Name        = "New POI",
                Description = "POI to test creating a new POI",
                Address     = "100 Main St.\nAnywhere, TX 75069"
            };

            _poiService.SavePOI(newPoi);

            var testId = newPoi.Id.GetValueOrDefault();

            _poiService.RefreshCache();

            var poi = _poiService.GetPOI(testId);

            Assert.IsNotNull(poi);
            Assert.AreEqual(poi.Name, "New POI");
        }
Exemplo n.º 2
0
        public void CreatePOI()
        {
            PointOfInterest newPOI = new PointOfInterest();

            newPOI.Name        = "NEW POI";
            newPOI.Description = "POI to test creating a new POI";
            newPOI.Address     = "100 Main Street";
            _poiService.SavePOI(newPOI);

            int testId = newPOI.Id.Value;

            // refresh the cache to be sure the data was
            // saved appropriately
            _poiService.RefreshCache();

            // verify if the newly create POI exists
            PointOfInterest poi = _poiService.GetPOI(testId);

            Assert.NotNull(poi);
            Assert.AreEqual(poi.Name, "NEW POI");
        }