public void TestConstructor() { this.point = new CoveragePoint("foo.txt", "bar", 1, 1, true); Assert.AreEqual(2, this.point.AbsoluteNumber); Assert.AreEqual(1, this.point.RelativeNumber); Assert.AreEqual("foo.txt", this.point.Filename); Assert.AreEqual("bar", this.point.Namespace); Assert.IsTrue(this.point.Hit); }
public void TestConstructors() { Coverage coverage; coverage = new Coverage(); Assert.IsNotNull(coverage.Settings); ReportSettings settings = new ReportSettings(); CoveragePoint[] points = new CoveragePoint[0]; coverage = new Coverage(settings, points); Assert.AreEqual(settings, coverage.Settings); Assert.AreEqual(points, coverage.CoveragePoints); }
public void SetUp() { this.point = new CoveragePoint(); this.point2 = new CoveragePoint(); }
/// <summary> /// Initializes a new instance of the <see cref="Coverage"/> class. /// </summary> /// <param name="settings">The settings.</param> /// <param name="points">The points.</param> public Coverage(ReportSettings settings, CoveragePoint[] points) { this.settings = settings; this.CoveragePoints = points; }
private string AddCoveragePoint(int Index) { CoveragePoint point = new CoveragePoint(filename, GetNamespace(Index), coveragepoints.Count + 1, baseCoveragePoint, false); coveragepoints.Add(point); point.LineNumber = IndexToLineNumber(Index); return point.GetCoverageCode(this.settings); }