Пример #1
0
        //[TestMethod]
        public void NestedGraphDoesNotThrow()
        {
            var o = new GetTopWinsResponse()
            {
                TopWins = new List <TopWinDto>()
                {
                    new TopWinDto()
                    {
                        Amount          = 1,
                        LandBasedCasino = new TopWinLandBasedCasino()
                        {
                            Location    = "Location",
                            MachineName = "Machinename"
                        },
                        Nickname     = "Nickname",
                        OnlineCasino = new TopWinOnlineCasino()
                        {
                            GameId = "GameId"
                        },
                        OnlineSports = new TopWinOnlineSports()
                        {
                            AwayTeam = "AwayTeam"
                        },
                        Timestamp = DateTime.Now,
                        Type      = TopWinType.LandBasedCasinoWin
                    }
                }
            };

            var actual = NetJSON.Serialize(o.GetType(), o);
        }
Пример #2
0
        //[TestMethod]
        public void NestedGraphDoesNotThrow()
        {
            var o = new GetTopWinsResponse()
            {
                TopWins = new List<TopWinDto>()
                {
                    new TopWinDto()
                    {
                        Amount = 1,
                        LandBasedCasino = new TopWinLandBasedCasino()
                        {
                            Location = "Location",
                            MachineName = "Machinename"
                        },
                        Nickname = "Nickname",
                        OnlineCasino = new TopWinOnlineCasino()
                        {
                            GameId = "GameId"
                        },
                        OnlineSports = new TopWinOnlineSports()
                        {
                            AwayTeam = "AwayTeam"
                        },
                        Timestamp = DateTime.Now,
                        Type = TopWinType.LandBasedCasinoWin
                    }
                }
            };

            var actual = NetJSON.Serialize(o.GetType(), o);
        }