mirror of
https://github.com/emilybache/GildedRose-Refactoring-Kata.git
synced 2026-10-16 10:55:09 +00:00
Refactoring c# projects (#544)
Small Refactoring c# projects, e.g. * add days * remove StartupObject * Fix Approval tests for NUnit * Use Environment.NewLine in Xunit tests * Added + fixed README.md * Removed global.json
This commit is contained in:
1 parent
a348b20789
commit
99f2fcbf18
17 files changed
+263
-236
No files matched your search
@@ -1,5 +1,4 @@
|
||||
|
||||
using GildedRoseKata;
|
||||
using GildedRoseKata;
|
||||
|
||||
using System;
|
||||
using System.IO;
|
||||
@@ -10,21 +9,20 @@ using VerifyXunit;
|
||||
|
||||
using Xunit;
|
||||
|
||||
namespace GildedRoseTests
|
||||
namespace GildedRoseTests;
|
||||
|
||||
public class ApprovalTest
|
||||
{
|
||||
public class ApprovalTest
|
||||
[Fact]
|
||||
public Task ThirtyDays()
|
||||
{
|
||||
[Fact]
|
||||
public Task ThirtyDays()
|
||||
{
|
||||
var fakeoutput = new StringBuilder();
|
||||
Console.SetOut(new StringWriter(fakeoutput));
|
||||
Console.SetIn(new StringReader("a\n"));
|
||||
var fakeoutput = new StringBuilder();
|
||||
Console.SetOut(new StringWriter(fakeoutput));
|
||||
Console.SetIn(new StringReader($"a{Environment.NewLine}"));
|
||||
|
||||
Program.Main(new string[] { "30" });
|
||||
var output = fakeoutput.ToString();
|
||||
Program.Main(new string[] { "30" });
|
||||
var output = fakeoutput.ToString();
|
||||
|
||||
return Verifier.Verify(output);
|
||||
}
|
||||
return Verifier.Verify(output);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user