forked from emilybache/GildedRose-Refactoring-Kata
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request emilybache#402 from claresudbery/csharp-approval-f…
…ixes Csharp approval fixes
- Loading branch information
Showing
5 changed files
with
34 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,3 +5,4 @@ obj | |
vendor | ||
.idea | ||
*.iml | ||
csharpcore/GildedRoseTests/ApprovalTest.ThirtyDays.received.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
using System; | ||
using System.IO; | ||
using System.Text; | ||
using ApprovalTests; | ||
using ApprovalTests.Reporters; | ||
using GildedRoseTests; | ||
using NUnit.Framework; | ||
|
||
namespace csharp | ||
{ | ||
[UseReporter(typeof(DiffReporter))] | ||
[TestFixture] | ||
public class ApprovalTest | ||
{ | ||
[Test] | ||
public void ThirtyDays() | ||
{ | ||
|
||
StringBuilder fakeoutput = new StringBuilder(); | ||
Console.SetOut(new StringWriter(fakeoutput)); | ||
Console.SetIn(new StringReader("a\n")); | ||
|
||
TexttestFixture.Main(new string[] { }); | ||
var output = fakeoutput.ToString(); | ||
|
||
Approvals.Verify(output); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters