Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2sharp.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornulltoken <emeric.fermas@gmail.com>2011-06-26 12:22:41 +0400
committernulltoken <emeric.fermas@gmail.com>2011-06-26 12:22:41 +0400
commitdfb856c9f9f19fcd38209a19ae6a7a21eb161959 (patch)
tree73d8089e8f239082ac92783419a2bedcbbbb73f6
parent608c8aef7e34ea7489f6136bc268d622f419d1ac (diff)
Leverage Sha abbreviating API in the tests
-rw-r--r--LibGit2Sharp.Tests/CommitFixture.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/LibGit2Sharp.Tests/CommitFixture.cs b/LibGit2Sharp.Tests/CommitFixture.cs
index 858cf0ad..e85c5cca 100644
--- a/LibGit2Sharp.Tests/CommitFixture.cs
+++ b/LibGit2Sharp.Tests/CommitFixture.cs
@@ -176,7 +176,7 @@ namespace LibGit2Sharp.Tests
{
var commits = repo.Commits.QueryBy(new Filter { Since = "refs/heads/br2", Until = "refs/heads/packed-test" });
- IEnumerable<string> abbrevShas = commits.Select(c => c.Id.Sha.Substring(0, 7)).ToArray();
+ IEnumerable<string> abbrevShas = commits.Select(c => c.Id.ToString(7)).ToArray();
CollectionAssert.AreEquivalent(new[] { "a4a7dce", "c47800c", "9fd738e" }, abbrevShas);
}
}
@@ -188,7 +188,7 @@ namespace LibGit2Sharp.Tests
{
var commits = repo.Commits.QueryBy(new Filter { Since = "a4a7dce", Until = "4a202b3" });
- IEnumerable<string> abbrevShas = commits.Select(c => c.Id.Sha.Substring(0, 7)).ToArray();
+ IEnumerable<string> abbrevShas = commits.Select(c => c.Id.ToString(7)).ToArray();
CollectionAssert.AreEquivalent(new[] { "a4a7dce", "c47800c", "9fd738e" }, abbrevShas);
}
}