Skip to content

Commit 1c6a28d

Browse files
tclemnulltoken
authored andcommitted
Add test coverage commits query through globed references
1 parent b6e924e commit 1c6a28d

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

LibGit2Sharp.Tests/CommitFixture.cs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -289,6 +289,28 @@ public void CanEnumerateCommitsFromMixedStartingPoints()
289289
});
290290
}
291291

292+
[Fact]
293+
public void CanEnumerateCommitsUsingGlob()
294+
{
295+
AssertEnumerationOfCommits(
296+
repo => new Filter { Since = repo.Refs.FromGlob("refs/heads/*") },
297+
new[]
298+
{
299+
"4c062a6", "e90810b", "6dcf9bf", "a4a7dce", "be3563a", "c47800c", "9fd738e", "4a202b3", "41bc8c6", "5001298", "5b5b025", "8496071"
300+
});
301+
}
302+
303+
[Fact]
304+
public void CanHideCommitsUsingGlob()
305+
{
306+
AssertEnumerationOfCommits(
307+
repo => new Filter { Since = "refs/heads/packed-test", Until = repo.Refs.FromGlob("*/packed") },
308+
new[]
309+
{
310+
"4a202b3", "5b5b025", "8496071"
311+
});
312+
}
313+
292314
[Fact]
293315
public void CanEnumerateCommitsFromAnAnnotatedTag()
294316
{

0 commit comments

Comments
 (0)