コード例 #1
0
        private void Initialize()
        {
            try { context.Entry(game).State = EntityState.Detached; }
            catch (Exception) { }

            wishlist = new WishLists()
            {
                WishId   = r.Next(),
                MemberId = "TestMemberId",
                GameId   = r.Next(),
                Game     = game,
            };
        }
コード例 #2
0
        private void Initialize()
        {
            try { context.Entry(gameReviews).State = EntityState.Detached; }
            catch (Exception) { }

            games = new Games()
            {
                GameId             = r.Next(),
                GameName           = "TestGame",
                ListPrice          = 10,
                ContentRating      = "R",
                Genre              = "TestGenre",
                AvailablePlatforms = "TestPlatform",
                MaxPlayers         = "100"
            };

            members = new Members()
            {
                MemberId      = "TestMemberId",
                DisplayName   = "TestDisplayName",
                FirstName     = "TestFirstName",
                LastName      = "TestLastName",
                Email         = "*****@*****.**",
                Password      = "******",
                Gender        = "M",
                BirthDate     = DateTime.Now,
                ReceiveEmails = false,
                CardType      = "TestCard",
                CardNumber    = "1234567890987654",
                CardExpires   = "05/24"
            };

            gameReviews = new GameReviews()
            {
                ReviewId   = r.Next(),
                MemberId   = members.MemberId,
                GameId     = games.GameId,
                GameReview = "TestGameReview",
                Game       = games,
                Member     = members
            };
        }
コード例 #3
0
        private void Initialize()
        {
            try { context.Entry(memberEvents).State = EntityState.Detached; }
            catch (Exception) { }

            events = new Events()
            {
                EventId   = r.Next(),
                EventName = "TestEvent",
                EventDate = DateTime.Now,
                StartTime = TimeSpan.Zero,
                EndTime   = TimeSpan.Zero,
                Capacity  = 500
            };

            memberEvents = new MemberEvents()
            {
                MemberEventsId = r.Next(),
                EventId        = events.EventId,
                MemberId       = "TestMemberId",
                Event          = events
            };
        }