public void DuplicateRuleShouldThrow()
 {
     Assert.Throws <ArgumentException>(() =>
     {
         _responseWithObject
         .TestBody("should blow up again", x => x.product[1].name != "")
         .TestBody("should blow up again", x => x.product[1].name != "");
     });
 }
Пример #2
0
 public void AccessingMissingNameShouldThrow()
 {
     Assert.Throws <AssertException>(() =>
     {
         _responseWithObject
         .TestBody("should blow up", x => x.products[0].name == "")
         .Assert("should blow up");
     });
 }
Пример #3
0
 public void ThenTheNewNameIsRight()
 {
     _responseContext
     .TestBody("name changed", x => x.id == ListId && x.name == ListName)
     .Assert("name changed");
 }
Пример #4
0
 public void RootIdShouldBeValid()
 {
     _responseWithObject
     .TestBody("root id exist", x => x.id.ToString() == "3a6b4e0b-8e5c-df11-849b-0014c258f21e")
     .Assert("root id exist");
 }
Пример #5
0
 public void ArrayResponseContentShouldPass()
 {
     _responseWithArray
     .TestBody("first item has AL", x => x[0].key == "AL")
     .Assert("first item has AL");
 }
 public void ThenTheFirstNameInTheListIsNotNull()
 {
     _responseContext
     .TestBody("name is not null", x => x[0].name != null)
     .Assert("name is not null");
 }