Ejemplo n.º 1
0
        public void Event_UserNull_ThrowsException()
        {
            Action act = () => new Event(SampleData.Party, SampleData.Description, SampleData.Category, SampleData.EventTime, SampleData.EndTime, SampleData.Cost, SampleData.AgeRestriction, null, SampleData.Location1234Spokane());

            Assert.Throws <ArgumentNullException>(act);
        }
Ejemplo n.º 2
0
        public void Event_Create_Success()
        {
            var eventHappnin = new Event(SampleData.Party, SampleData.Description, SampleData.Category, SampleData.EventTime, SampleData.EndTime, SampleData.Cost, SampleData.AgeRestriction, SampleData.UserKyle(), SampleData.Location1234Spokane());

            Assert.Equal(SampleData.Party, eventHappnin.Name);
            Assert.Equal(SampleData.Description, eventHappnin.Description);
            Assert.Equal(SampleData.Location1234Spokane().City, eventHappnin.Location.City);
            Assert.Equal(SampleData.Kyle, eventHappnin.Host.FirstName);
            Assert.Equal(SampleData.EventTime, eventHappnin.EventTime);
            Assert.Equal(SampleData.Cost, eventHappnin.Cost);
            Assert.Equal(SampleData.AgeRestriction, eventHappnin.AgeRestriction);
        }