本文整理汇总了C#中SvnClient.Log方法的典型用法代码示例。如果您正苦于以下问题:C# SvnClient.Log方法的具体用法?C# SvnClient.Log怎么用?C# SvnClient.Log使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类SvnClient
的用法示例。
在下文中一共展示了SvnClient.Log方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Log_ExpectLogException
public void Log_ExpectLogException()
{
using (SvnClient client = new SvnClient())
{
// Throws an SvnRepositoryIOException in [email protected]
List<Uri> uris = new List<Uri>();
uris.Add(new Uri("http://svn.apache.org/repos/asf/subversion/README"));
uris.Add(new Uri("http://svn.apache.org/repos/asf/subversion/INSTALL"));
SvnLogArgs args = new SvnLogArgs();
client.Log(uris, args, delegate(object sender, SvnLogEventArgs e)
{ });
}
}
示例2: Log_LogFromFile
public void Log_LogFromFile()
{
SvnSandBox sbox = new SvnSandBox(this);
Uri repos = sbox.CreateRepository(SandBoxRepository.MergeScenario);
string dir = sbox.Wc;
using (SvnClient client = new SvnClient())
{
client.CheckOut(new Uri(repos, "trunk/"), dir);
int n = 0;
client.Log(Path.Combine(dir, "index.html"),
delegate(object sender, SvnLogEventArgs e)
{
switch (n++)
{
case 0:
Assert.That(e.LogMessage, Is.EqualTo("Merge branch b - product roadmap and update about page"));
break;
case 1:
Assert.That(e.LogMessage, Is.EqualTo("Merge branch a. Added medium product"));
break;
case 2:
Assert.That(e.LogMessage, Is.EqualTo("Create initial product structure"));
break;
}
});
Assert.That(n, Is.EqualTo(3));
}
}