예제 #1
0
        public void GetStatistics_IncludesCount()
        {
            // statistics is the info about the counter in regards to other counters
            var statistics = new CounterManager().GetStatistics(_counter, 5);

            Assert.Equal(5, statistics.Count);
        }
예제 #2
0
        public void Statistics_ShowsPercentageUpToTwoBasedOnTotalCount(int count, int total, double expected)
        {
            _counter.Count = count;

            var statistics = new CounterManager().GetStatistics(_counter, total);

            Assert.Equal(expected, statistics.Percent);      // this is just one counter
        }