public void TransformToFPlaces_WhenCorrectVenues_ShouldReturnListOfFPlaces()
        {
            List <Venue> venues = new List <Venue>();

            venues.Add(new Venue {
                id = "1"
            });
            venues.Add(new Venue {
                id = "2"
            });
            venues.Add(new Venue {
                id = "3"
            });

            List <FPlace> places = TransformerHelpers.TransformToFPlaces(venues, null);

            Assert.IsNotNull(places);
            Assert.IsTrue(places.Count > 0);
        }
        public void TransformToFPlaces_WhenCheckinsProvided_ShouldReturnListOfFPlacesWithFriendsNames()
        {
            List <Venue> venues = new List <Venue>();
            var          venue  = new Venue {
                id = "1"
            };

            venues.Add(venue);
            venue = new Venue {
                id = "2"
            };
            venues.Add(venue);
            venue = new Venue {
                id = "3"
            };
            venues.Add(venue);
            List <Checkin> checkins = new List <Checkin>();

            checkins.Add(new Checkin
            {
                venue = venue,
                user  = new User
                {
                    firstName = "John",
                    lastName  = "Luther"
                }
            });

            List <FPlace> places = TransformerHelpers.TransformToFPlaces(venues, checkins);

            Assert.IsNotNull(places);
            Assert.IsTrue(places.Count > 0);

            FPlace place = places.Find(p => p.Id == "3");

            Assert.IsNotNull(place);
            Assert.IsTrue(place.FriendsHere.Contains("John Luther"));
        }
        public void TransformToFPlaces_WhenEmptyVenues_ShouldReturnEmptyListOfFPlaces()
        {
            List <FPlace> places = TransformerHelpers.TransformToFPlaces(new List <Venue>(), null);

            Assert.IsTrue(places.Count == 0);
        }
 public void TransformToFPlaces_WhenVenuesNull_ShouldThrowArgumentNullException()
 {
     TransformerHelpers.TransformToFPlaces(null, null);
 }