コード例 #1
0
        public void AssertResultsByGameGameRowUserData(int expUserId, string expPicked, string expPick, int expBet, int expResult, int expPotentialGain, int expPotentialLoss, ResultsByGameGameRowUserData actual)
        {
            bool expPickedFavorite = false;
            bool expPickedUnderdog = false;
            bool expPickedNoBet = false;
            bool expPickedNoPicks = false;

            if (expPicked == "Favorite") expPickedFavorite = true;
            if (expPicked == "Underdog") expPickedUnderdog = true;
            if (expPicked == "NoBet") expPickedNoBet = true;
            if (expPicked == "NoPicks") expPickedNoPicks = true;

            Assert.AreEqual(expUserId, actual.UserId, "UserId not equal");
            Assert.AreEqual(expPickedFavorite, actual.PickedFavorite, "PickedFavorite not equal");
            Assert.AreEqual(expPickedUnderdog, actual.PickedUnderdog, "PickedUnderdog not equal");
            Assert.AreEqual(expPickedNoBet, actual.PickedNoBet, "PickedNoBet not match");
            Assert.AreEqual(expPickedNoPicks, actual.PickedNoPicks, "PickedNoPicks not equal");
            Assert.AreEqual(expPick.TrimEnd(), actual.Pick.TrimEnd(), "Pick not equal");
            Assert.AreEqual(expBet, actual.Bet, "Bet not equal");
            Assert.AreEqual(expPotentialGain, actual.PotentialGain, "PotentialGain not equal");
            Assert.AreEqual(expPotentialLoss, actual.PotentialLoss, "PotentialLoss not equal");
            Assert.AreEqual(expResult, actual.Result, "Result not equal");
        }
コード例 #2
0
        public void AssertResultsByGameGameRowUserData(int gameFilterId, int gameRowId, int expUserId, string expPicked, string expPick, int expBet, int expResult, int expPotentialGain, int expPotentialLoss, ResultsByGameGameRowUserData actual)
        {
            bool expPickedFavorite = false;
            bool expPickedUnderdog = false;
            bool expPickedNoBet = false;
            bool expPickedNoPicks = false;

            if (expPicked == "Favorite") expPickedFavorite = true;
            if (expPicked == "Underdog") expPickedUnderdog = true;
            if (expPicked == "NoBet") expPickedNoBet = true;
            if (expPicked == "NoPicks") expPickedNoPicks = true;

            Assert.AreEqual(expUserId, actual.UserId, string.Format("UserId not equal for GameFilterId:{0} GameRowId:{1}", gameFilterId, gameRowId));
            Assert.AreEqual(expPickedFavorite, actual.PickedFavorite, string.Format("PickedFavorite not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPickedUnderdog, actual.PickedUnderdog, string.Format("PickedUnderdog not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPickedNoBet, actual.PickedNoBet, string.Format("PickedNoBet not match for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPickedNoPicks, actual.PickedNoPicks, string.Format("PickedNoPicks not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPick.TrimEnd(), actual.Pick.TrimEnd(), string.Format("Pick not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expBet, actual.Bet, string.Format("Bet not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPotentialGain, actual.PotentialGain, string.Format("PotentialGain not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expPotentialLoss, actual.PotentialLoss, string.Format("PotentialLoss not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
            Assert.AreEqual(expResult, actual.Result, string.Format("Result not equal for GameFilterId:{0} GameRowId:{1} UserId:{2}", gameFilterId, gameRowId, expUserId));
        }