private async Task ValidateRiskLevelCriteriaCheck(Guid riskLevelForRpc, FraudRiskLevelStatus expectedResult)
        {
            var playerId = new Guid();

            playerId = PickAPlayer(playerId);

            CreateAvcConfiguration(new AVCConfigurationDTO
            {
                Licensee          = _observedBrand.LicenseeId,
                Brand             = _observedBrand.Id,
                Currency          = _observedBrand.DefaultCurrency,
                VipLevels         = new[] { (Guid)_observedBrand.DefaultVipLevelId },
                HasFraudRiskLevel = true,
                RiskLevels        = new[] { _observedRiskLevel },
                Status            = AutoVerificationCheckStatus.Active
            });

            _riskProfileCheckCommands.Create(new RiskProfileCheckDTO
            {
                Licensee          = _observedBrand.LicenseeId,
                Brand             = _observedBrand.Id,
                Currency          = _observedBrand.DefaultCurrency,
                VipLevels         = new[] { (Guid)_observedBrand.DefaultVipLevelId },
                HasFraudRiskLevel = true,
                RiskLevels        = new[] { riskLevelForRpc },
            });

            await DepositBetAndWin(playerId);

            var offlineWithdrawalRequest = new OfflineWithdrawRequest
            {
                Amount              = 1,
                NotificationType    = NotificationType.None,
                BankAccountTime     = _paymentRepository.PlayerBankAccounts.First().Created.ToString(),
                BankTime            = _paymentRepository.Banks.First().Created.ToString(),
                PlayerBankAccountId = _paymentRepository
                                      .PlayerBankAccounts
                                      .Include(x => x.Player)
                                      .First(x => x.Player.Id == playerId)
                                      .Id,
                Remarks     = "asd",
                RequestedBy = _actorInfoProvider.Actor.UserName
            };

            AssertRiskProfileCheckStatus(offlineWithdrawalRequest,
                                         _observedBrand,
                                         expectedResult);
        }
        private void AssertRiskProfileCheckStatus(OfflineWithdrawRequest offlineWithdrawalRequest,
                                                  Core.Brand.Interface.Data.Brand brand, FraudRiskLevelStatus expectedResult)
        {
            var response = _withdrawalService.Request(offlineWithdrawalRequest);

            var riskProfileCheckReportInfo = _withdrawalVerificationLogsQueues.RiskProfileCheckStatus(response.Id,
                                                                                                      brand.Name, brand.Licensee.Name, "Random Name");

            Assert.AreEqual(expectedResult.ToString(),
                            riskProfileCheckReportInfo.VerificationDialogHeaderValues.StatusSuccess);
        }
        public async void Win_Loss_rule_is_interpreted_in_oposite_manner_between_AVC_and_RPC(ComparisonEnum comparison, FraudRiskLevelStatus status)
        {
            var playerId = new Guid();

            playerId = PickAPlayer(playerId);

            CreateAvcConfiguration(new AVCConfigurationDTO
            {
                Licensee  = _observedBrand.LicenseeId,
                Brand     = _observedBrand.Id,
                Currency  = _observedBrand.DefaultCurrency,
                VipLevels = new[] { (Guid)_observedBrand.DefaultVipLevelId },

                HasWinLoss      = true,
                WinLossAmount   = 5,
                WinLossOperator = ComparisonEnum.Greater,

                Status = AutoVerificationCheckStatus.Active
            });

            _riskProfileCheckCommands.Create(new RiskProfileCheckDTO
            {
                Licensee  = _observedBrand.LicenseeId,
                Brand     = _observedBrand.Id,
                Currency  = _observedBrand.DefaultCurrency,
                VipLevels = new[] { (Guid)_observedBrand.DefaultVipLevelId },

                HasWinLoss      = true,
                WinLossAmount   = 5,
                WinLossOperator = comparison,
            });

            await DepositBetAndWin(playerId);

            var offlineWithdrawalRequest = new OfflineWithdrawRequest
            {
                Amount              = 1,
                NotificationType    = NotificationType.None,
                BankAccountTime     = _paymentRepository.PlayerBankAccounts.First().Created.ToString(),
                BankTime            = _paymentRepository.Banks.First().Created.ToString(),
                PlayerBankAccountId = _paymentRepository
                                      .PlayerBankAccounts
                                      .Include(x => x.Player)
                                      .First(x => x.Player.Id == playerId)
                                      .Id,
                Remarks     = "asd",
                RequestedBy = _actorInfoProvider.Actor.UserName
            };

            AssertRiskProfileCheckStatus(offlineWithdrawalRequest,
                                         _observedBrand,
                                         status);
        }