Ejemplo n.º 1
0
        public void CreatesNewLineForEachOutputAndFormatsAccordinglyWhenCommitlistIsNull()
        {
            var expectedOutput = "";
            var repositoryData = new RepositoryData(null, "repositoryName", "username");

            var formattedData = repositoryData.ToString();

            Assert.AreEqual(formattedData, expectedOutput);
        }
Ejemplo n.º 2
0
        public void CreatesNewLineForEachOutputAndFormatsAccordinglyWhenOneCommitIsNull()
        {
            var fakeCommits = new List <GitHubCommit> {
                FakeGithubCommit, FakeGithubCommit2, Fake.GetNullCommit()
            };
            var repositoryData = new RepositoryData(fakeCommits, "repositoryName", "username");
            var expectedOutput = "[repositoryName]/[f78a226e32eb6a0320f2003859ed4d08caa53878]: refactoring [svitra]" + Environment.NewLine + "[repositoryName]/[6d95eaea321145383153692a802099577ea74c95]: cr changes [bleble]" + Environment.NewLine + "[repositoryName]/[]:  []";

            var formattedData = repositoryData.ToString();

            Assert.AreEqual(formattedData, expectedOutput);
        }