You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
33 lines
715 B
33 lines
715 B
using Model;
|
|
|
|
namespace Model_UnitTests
|
|
{
|
|
public class Recipe_UT
|
|
{
|
|
[Fact]
|
|
public void TestConstructorNotNull()
|
|
{
|
|
Recipe r1 = new Recipe("R1");
|
|
Assert.NotNull(r1);
|
|
}
|
|
|
|
[Fact]
|
|
public void TestConstructorWithValidDefaults()
|
|
{
|
|
Recipe r2 = new Recipe("Recipe n2");
|
|
Assert.Equal("Recipe n2", r2.Title);
|
|
Assert.Equal("No Description.", r2.Description);
|
|
}
|
|
|
|
[Fact]
|
|
public void TestRecipeId()
|
|
{
|
|
Recipe r3 = new Recipe("R3");
|
|
Recipe r4 = new Recipe("R4");
|
|
|
|
Assert.Equal(2, r3.Id);
|
|
Assert.Equal(3, r4.Id);
|
|
}
|
|
}
|
|
}
|