|
@ -1,13 +1,28 @@ |
|
|
using System; |
|
|
|
|
|
|
|
|
using MiniGames.Shared.Models; |
|
|
|
|
|
using System; |
|
|
using System.Collections.Generic; |
|
|
using System.Collections.Generic; |
|
|
using System.Linq; |
|
|
using System.Linq; |
|
|
using System.Text; |
|
|
using System.Text; |
|
|
using System.Threading.Tasks; |
|
|
using System.Threading.Tasks; |
|
|
|
|
|
using Xunit; |
|
|
|
|
|
|
|
|
namespace MiniGamesTests |
|
|
namespace MiniGamesTests |
|
|
{ |
|
|
{ |
|
|
public class TicTacToeBrettTest |
|
|
public class TicTacToeBrettTest |
|
|
{ |
|
|
{ |
|
|
|
|
|
[Theory] |
|
|
|
|
|
[InlineData(4, 0, true)] |
|
|
|
|
|
public void Set_FreiesFeldBelegenTest(int pos, int wert, bool gesetzt) |
|
|
|
|
|
{ |
|
|
|
|
|
// arrange
|
|
|
|
|
|
TicTacToeBrett brett = new(); |
|
|
|
|
|
bool erwartetGesetzt = gesetzt; |
|
|
|
|
|
|
|
|
|
|
|
// act
|
|
|
|
|
|
bool erhaltenGesetzt = brett.set(pos, wert); |
|
|
|
|
|
|
|
|
|
|
|
// assert
|
|
|
|
|
|
Assert.Equal(erwartetGesetzt, erhaltenGesetzt); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |