Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

Abstract LibGit2Sharp away in testing context #185

Closed
wants to merge 14 commits into
from

Conversation

Projects
None yet
4 participants
Contributor

yorah commented Jun 16, 2012

This pull request is related to #138, and is a follow-up of #182.

Changes:

  • An IRepository interface has been introduced.
  • The most commonly used classes have been made mockable.
  • I also added a MockedRepositoryFixture, which shows how to abstract LibGit2sharp in a testing context. If you have a better name for this fixture, please tell!

@Haacked @nulltoken Would you please be so kind as to review this PR?

Contributor

yorah commented Jun 17, 2012

@nulltoken I pushed a new version of the PR. Basically, I removed the RepositoryExtensionsFixture, because as Haaced already said in #138, I don't see the point in having tests just for the sake of showing proper isolation of the interfaces.

Shameless quote: I just see it as the product of good design, not as a separate feature that requires tests itself.

Please tell me if you're ok with that, or if you want me to reintroduce RepositoryExtensionsFixture in this PR.

Member

nulltoken commented Jun 18, 2012

👍 for me. Thanks for this!

Contributor

Haacked commented Jun 18, 2012

Looks good to me. Any reason we don't apply this to all objects from now on?

Member

tclem commented Jun 18, 2012

Nice @yorah! I'm happy with this too.

Member

nulltoken commented Jun 18, 2012

Any reason we don't apply this to all objects from now on?

@Haacked you're right! I've created #186 to cope with this.

Member

nulltoken commented Jun 18, 2012

@yorah Merged. Very nice job! ❤️

@nulltoken nulltoken closed this Jun 18, 2012

Contributor

Haacked commented Jun 18, 2012

❤️ thanks everybody!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment