コード例 #1
0
        public void ShouldCountLines()
        {
            var file = Path.Combine(_testRoot, "x.txt");

            CreateContentInFile(file, 0);
            Assert.AreEqual(0, _sut.CountLines(file));

            CreateContentInFile(file, 1);
            Assert.AreEqual(1, _sut.CountLines(file));

            CreateContentInFile(file, 10);
            Assert.AreEqual(10, _sut.CountLines(file));
        }