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); }
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); }
public void JiraRestClient_Ctor_StringUri_NotAbsolute() { JiraRestClient client = new JiraTestRestClient("/test/super.jpg"); Assert.IsNotNull(client); }
public void JiraRestClient_Ctor_StringUri_Required() { JiraRestClient client = new JiraTestRestClient(string.Empty); Assert.IsNull(client); }
public void JiraRestClient_Ctor_Uri_NotAbsolute() { Uri serverUrl = new Uri("~/test/super.jpg", UriKind.Relative); JiraRestClient client = new JiraTestRestClient(serverUrl); Assert.IsNull(client); }
public void JiraRestClient_Ctor_Uri_Required() { JiraRestClient client = new JiraTestRestClient((Uri)null); Assert.IsNull(client); }