Ejemplo n.º 1
0
        public void WhenParsingDirectoryRenameShouldReturnExpectedValues()
        {
            var context = new GitLogParserContext();

            context.CurrentCommit = new GitCommit();
            parser.ProcessRenames(context, "some/root/{ => another/added/dir}/SomeFile.cpp");

            Assert.Equal("some/root/another/added/dir/SomeFile.cpp", context.CurrentCommit.ChangesetFileRenames["some/root/SomeFile.cpp"]);
        }
Ejemplo n.º 2
0
        public void WhenParsingFileNameRenameWithoutPartialTreeShouldReturnExpectedValues()
        {
            var context = new GitLogParserContext();

            context.CurrentCommit = new GitCommit();
            parser.ProcessRenames(context, "OldFileName.h => NewFileName.h");

            Assert.Equal("NewFileName.h", context.CurrentCommit.ChangesetFileRenames["OldFileName.h"]);
        }