public void ProjectsTest() { thinkproject.RestClient c = new thinkproject.RestClient(Properties.Settings.Default.BaseUri, Properties.Settings.Default.AppKey); c.Authenticate(Properties.Settings.Default.Username, Properties.Settings.Default.Password); var p = thinkproject.Project.GetProjects(c); Assert.IsNotNull(p); }
public void DFDTest() { thinkproject.RestClient c = new thinkproject.RestClient(Properties.Settings.Default.BaseUri, Properties.Settings.Default.AppKey); c.Authenticate(Properties.Settings.Default.Username, Properties.Settings.Default.Password); var p = thinkproject.Project.GetProjects(c); var dfd = thinkproject.DocumentFormDefinition.GetDocumentFormDefinitions(p[0], c); Assert.IsNotNull(dfd); }
public void DocumentTest() { thinkproject.RestClient c = new thinkproject.RestClient(Properties.Settings.Default.BaseUri, Properties.Settings.Default.AppKey); c.Authenticate(Properties.Settings.Default.Username, Properties.Settings.Default.Password); var p = thinkproject.Project.GetProjects(c); var dfd = thinkproject.Filter.GetFilters(p[0], c); var docs = thinkproject.Document.GetDocuments(dfd[6], c); Assert.IsNotNull(docs); }
public static bool Connect(string appKey, string baseUri, string username, string password) { try { Connection = new thinkproject.RestClient(baseUri, appKey); Connection.Authenticate(username, password); return(Connection.IsAuthenticated); } catch (Exception e) { return(false); } }
public void AuthTest() { thinkproject.RestClient c = new thinkproject.RestClient(Properties.Settings.Default.BaseUri, Properties.Settings.Default.AppKey); c.Authenticate(Properties.Settings.Default.Username, Properties.Settings.Default.Password); Assert.IsTrue(c.IsAuthenticated); }