Skip to content

Encourage writing RepositoryFixture tests #2289

New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 15 additions & 2 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,21 @@ A clear and concise description of what the bug is.
<!-- Not obligatory, but suggest a fix or reason for the bug -->

## Steps to Reproduce
<!-- Provide a link to a live example, or an unambiguous set of steps to -->
<!-- reproduce this bug. Include code to reproduce, if relevant -->
<!--
If you are able to write your bug or scenario up as a `RepositoryFixture` test
and submit a pull-request with it, it is going to increase the likelyhood of
the bug being fixed.

It will both make it easier to understand what you are trying to achieve, how
GitVersion deviates from this expectation and to start debugging the problem. It
will also make it easier for you to fix the problem yourself. Please look at the
following example for how such a test can look like:

https://github.com/GitTools/GitVersion/blob/251645f08802ea9dc401d5b2f2d681e8f8adf626/src/GitVersionCore.Tests/IntegrationTests/MasterScenarios.cs#L13-L32

Otherwise, please provide a link to a live example, or an unambiguous set of
steps to reproduce this bug.
-->

## Context
<!-- How has this bug affected you? What were you trying to accomplish? -->
Expand Down
3 changes: 2 additions & 1 deletion .github/ISSUE_TEMPLATE/failing-test.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@ assignees: ''
A clear and concise description of what the bug is or a link to it

## Test code
```

```csharp
using var fixture = new EmptyRepositoryFixture();
fixture.Repository.MakeACommit();
fixture.BranchTo("develop");
Expand Down
18 changes: 16 additions & 2 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,24 @@ assignees: ''
---

**Is your feature request related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
A clear and concise description of what the problem is. Ex. I'm always
frustrated when [...]

## Detailed Description
<!--- Provide a detailed description of the change or addition you are proposing -->
<!---
Provide a detailed description of the change or addition you are proposing.

If you are able to write your feature or scenario up as a `RepositoryFixture`
test and submit a pull-request with it, it is going to increase the likelyhood
of the feature being implemented.

It will both make it easier to understand what you are trying to achieve, how
GitVersion deviates from this expectation and to start debugging the problem. It
will also make it easier for you to implement the feature yourself. Please look
at the following example for how such a test can look like:

https://github.com/GitTools/GitVersion/blob/251645f08802ea9dc401d5b2f2d681e8f8adf626/src/GitVersionCore.Tests/IntegrationTests/MasterScenarios.cs#L13-L32
-->

## Context
<!--- Why is this change important to you? How would you use it? -->
Expand Down