Example #1
0
        public void Zero_report_interval()
        {
            var intersection = session.Query <TestIntersection>()
                               .First(i => i.Price == order.Price && i.Client == order.Client);

            intersection.SupplierClientId = Guid.NewGuid().ToString();
            session.Save(intersection);

            order.WriteTime = DateTime.Now;

            Property("Type", 3);
            TryInitReport <SupplierMarketShareByUser>();
            ((BaseOrdersReport)report).ReportPeriod = ReportPeriod.ByToday;
            var sheet = ReadReport <SupplierMarketShareByUser>();

            Assert.AreEqual(order.Sum().ToString("C"), ValueByColumn(sheet, intersection.SupplierClientId, "Сумма по 'Тестовый поставщик'"));
        }