Permalink
Browse files

Don't force filters to have Since

  • Loading branch information...
1 parent ac04feb commit 9153f74a070bc907e1acaf76373c342cb1763058 @tclem tclem committed Jun 15, 2012
Showing with 0 additions and 5 deletions.
  1. +0 −3 LibGit2Sharp.Tests/CommitFixture.cs
  2. +0 −2 LibGit2Sharp/CommitCollection.cs
@@ -98,7 +98,6 @@ public void QueryingTheCommitHistoryWithUnknownShaOrInvalidEntryPointThrows()
{
Assert.Throws<LibGit2SharpException>(() => repo.Commits.QueryBy(new Filter { Since = Constants.UnknownSha }).Count());
Assert.Throws<LibGit2SharpException>(() => repo.Commits.QueryBy(new Filter { Since = "refs/heads/deadbeef" }).Count());
- Assert.Throws<ArgumentNullException>(() => repo.Commits.QueryBy(new Filter { Since = null }).Count());
}
}
@@ -120,8 +119,6 @@ public void QueryingTheCommitHistoryWithBadParamsThrows()
{
using (var repo = new Repository(BareTestRepoPath))
{
- Assert.Throws<ArgumentException>(() => repo.Commits.QueryBy(new Filter { Since = string.Empty }));
- Assert.Throws<ArgumentNullException>(() => repo.Commits.QueryBy(new Filter { Since = null }));
Assert.Throws<ArgumentNullException>(() => repo.Commits.QueryBy(null));
}
}
@@ -80,8 +80,6 @@ IEnumerator IEnumerable.GetEnumerator()
public ICommitCollection QueryBy(Filter filter)
{
Ensure.ArgumentNotNull(filter, "filter");
- Ensure.ArgumentNotNull(filter.Since, "filter.Since");
- Ensure.ArgumentNotNullOrEmptyString(filter.Since.ToString(), "filter.Since");
return new CommitCollection(repo, filter);
}

0 comments on commit 9153f74

Please sign in to comment.