Skip to content

Abstract LibGit2Sharp away in testing context#185

Closed
yorah wants to merge 14 commits into
libgit2:vNextfrom
yorah:interfaces
Closed

Abstract LibGit2Sharp away in testing context#185
yorah wants to merge 14 commits into
libgit2:vNextfrom
yorah:interfaces

Conversation

@yorah

@yorah yorah commented Jun 16, 2012

Copy link
Copy Markdown
Contributor

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?

@yorah

yorah commented Jun 17, 2012

Copy link
Copy Markdown
Contributor Author

@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.

@nulltoken

Copy link
Copy Markdown
Member

👍 for me. Thanks for this!

@haacked

haacked commented Jun 18, 2012

Copy link
Copy Markdown
Contributor

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

@tclem

tclem commented Jun 18, 2012

Copy link
Copy Markdown
Member

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

@nulltoken

Copy link
Copy Markdown
Member

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.

@nulltoken

Copy link
Copy Markdown
Member

@yorah Merged. Very nice job! ❤️

@nulltoken nulltoken closed this Jun 18, 2012
@haacked

haacked commented Jun 18, 2012

Copy link
Copy Markdown
Contributor

❤️ thanks everybody!

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants