Ejemplo n.º 1
0
 public void JiraRestClient_Ctor_BaseUrl_WellFormatted()
 {
     JiraRestClient client = new JiraTestRestClient("http://www.jira.com:8080/server");
     Assert.IsNotNull(client);
     // final Url used server Url base (without subfolder/virtual dir) combined with jira rest api path => subfolder/virtual dir are truncated
     Assert.AreEqual(new Uri("http://www.jira.com:8080/rest/api/latest/"), client.BaseUrl);
 }
Ejemplo n.º 2
0
 public void JiraRestClient_Ctor_StringUri_OK()
 {
     Uri serverUri = new Uri("http://www.google.fr");
     JiraRestClient client = new JiraTestRestClient("http://www.google.fr");
     Assert.IsNotNull(client);
     Assert.AreEqual(serverUri, client.ServerUrl);
 }
Ejemplo n.º 3
0
 public void JiraRestClient_Ctor_StringUri_NotAbsolute()
 {
     JiraRestClient client = new JiraTestRestClient("/test/super.jpg");
     Assert.IsNotNull(client);
 }
Ejemplo n.º 4
0
 public void JiraRestClient_Ctor_StringUri_Required()
 {
     JiraRestClient client = new JiraTestRestClient(string.Empty);
     Assert.IsNull(client);
 }
Ejemplo n.º 5
0
 public void JiraRestClient_Ctor_Uri_NotAbsolute()
 {
     Uri serverUrl = new Uri("~/test/super.jpg", UriKind.Relative);
     JiraRestClient client = new JiraTestRestClient(serverUrl);
     Assert.IsNull(client);
 }
Ejemplo n.º 6
0
 public void JiraRestClient_Ctor_Uri_Required()
 {
     JiraRestClient client = new JiraTestRestClient((Uri)null);
     Assert.IsNull(client);
 }