Exemplo n.º 1
0
 public static void ShouldHaveDeleteLink(this ViewWithLinks view, string url)
 {
     view.DeleteLink()
     .ShouldBeDelete()
     .EndingWith(url);
 }
Exemplo n.º 2
0
 public static void ShouldHaveUpdateLink(this ViewWithLinks view, string url)
 {
     view.UpdateLink()
     .ShouldBePut()
     .EndingWith(url);
 }
Exemplo n.º 3
0
 public static LinkView Link(this ViewWithLinks view, string relType)
 {
     return(view.Links.SingleOrDefault(l => l.Rel.Equals(relType, StringComparison.CurrentCultureIgnoreCase)));
 }
Exemplo n.º 4
0
 public static IEnumerable <LinkView> Links(this ViewWithLinks view, string relType)
 {
     return(view.Links.Where(l => l.Rel.Equals(relType, StringComparison.CurrentCultureIgnoreCase)));
 }
Exemplo n.º 5
0
 public static LinkView CreateWordLink(this ViewWithLinks view)
 {
     return(view.Links.SingleOrDefault(l => l.Rel.Equals(RelTypes.CreateWord, StringComparison.CurrentCultureIgnoreCase)));
 }