Пример #1
0
        public async void Can_get_filtered_bonuses()
        {
            var bonus = CreateFirstDepositBonus(isActive: false);

            var request = new FilteredDataRequest
            {
                PageIndex  = 1,
                RowCount   = 20,
                SortSord   = "asc",
                SortColumn = "Name",
                TopRecords = 20,
                Filters    = new[]
                {
                    new Filter
                    {
                        Field      = "Name",
                        Comparison = ComparisonOperator.Eq,
                        Data       = bonus.Name
                    }
                }
            };
            var result = await ApiProxy.GetFilteredBonusesAsync(new BrandFilteredDataRequest
            {
                DataRequest  = request,
                BrandFilters = new List <Guid> {
                    DefaultBrandId
                }
            });

            result.Should().NotBeNull();
            result.Rows.Count.Should().Be(1);
        }