public void StartingOneSection()
		{
			var profiler = new CodeProfiler();
			profiler.Start(ProfilingMode.Rendering, Section1);
			Assert.IsTrue(
				profiler.GetProfilingResultsSummary(ProfilingMode.Rendering).StartsWith(OneSection));
		}
        public void NeverStartingReportsNothingProfiled()
        {
            var profiler = new CodeProfiler();

            Assert.AreEqual(NothingProfiled,
                            profiler.GetProfilingResultsSummary(ProfilingMode.Rendering));
        }
        public void StartingOneSection()
        {
            var profiler = new CodeProfiler();

            profiler.Start(ProfilingMode.Rendering, Section1);
            Assert.IsTrue(
                profiler.GetProfilingResultsSummary(ProfilingMode.Rendering).StartsWith(OneSection));
        }
        public void EmptyProfilingSummary()
        {
            var profilingResults          = new CodeProfilingResults(new List <CodeProfilerSection>());
            var profilingResultsFormatter = new CodeProfilingResultsFormatter(profilingResults);
            var profiler = new CodeProfiler();

            Assert.AreEqual(profilingResultsFormatter.Summary,
                            profiler.GetProfilingResultsSummary(ProfilingMode.Rendering));
        }
		public void NeverStartingReportsNothingProfiled()
		{
			var profiler = new CodeProfiler();
			Assert.AreEqual(NothingProfiled,
				profiler.GetProfilingResultsSummary(ProfilingMode.Rendering));
		}
Esempio n. 6
0
		public void EmptyProfilingSummary()
		{
			var profilingResults = new CodeProfilingResults(new List<CodeProfilerSection>());
			var profilingResultsFormatter = new CodeProfilingResultsFormatter(profilingResults);
			var profiler = new CodeProfiler();
			Assert.AreEqual(profilingResultsFormatter.Summary,
				profiler.GetProfilingResultsSummary(ProfilingMode.Rendering));
		}