Contents tagged with Theory
today I want to share with you small explanation about how xUnit works.
Take a look at presented code:
[InlineData(3, 4, 5)]
[InlineData(7, 8, 9)]
public void MethodDemo(int numberOne, int numberTwo, int numberThree)
double data = new double;
data = new double;
data = numberOne;
data = numberTwo;
data = numberThree;
var sut = new Matrix(data);
If to describe this code in words, it has following meaning.
Attribute Theory says that it is test method which should be exeuted.
Repeated twice Attribute InlineData says that method MethodDemo should be executed twice, with assigning to … more