Exemplo n.º 1
0
 public void CreateLinkHeaderWithRelation()
 {
     var link = new Link() { Target = new Uri("http://localhost/{?foo}"),
         Relation = "related",
         Title = "foo"
     };
     Assert.Equal("<http://localhost/{?foo}>;rel=\"related\";title=\"foo\"", link.AsLinkHeader());
 }
Exemplo n.º 2
0
 public void CreateLinkHeaderWithMediaTypeAndLanguages()
 {
     var link = new Link()
     {
         Target = new Uri("http://localhost/{?foo}"),
         Type = "application/foo"
     };
     link.HrefLang.Add(new CultureInfo("en-GB"));
     link.HrefLang.Add(new CultureInfo("en-CA"));
     Assert.Equal("<http://localhost/{?foo}>;rel=\"related\";hreflang=en-GB;hreflang=en-CA;type=\"application/foo\"", link.AsLinkHeader());
 }
Exemplo n.º 3
0
 public void CreateLinkHeader()
 {
     var link = new Link() { Target = new Uri("http://localhost/{?foo}") };
     Assert.Equal("<http://localhost/{?foo}>;rel=\"related\"", link.AsLinkHeader());
 }