Created Unit Test Project
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||
using System;
|
||||
using PWAPPv2.Source.API;
|
||||
using PWAPPv2.Source.DataObjects;
|
||||
|
||||
// System.Threading.Tasks.Task<TResult>.Result.get returned "\"1|Endo|2|Implant|3|Oral Surgery|4|Ortho|5|Pedo|6|Perio|7|Restore|8|Other \\n\"" string
|
||||
|
||||
namespace UnitTests
|
||||
{
|
||||
[TestClass]
|
||||
public class UnitTest1
|
||||
{
|
||||
[TestMethod]
|
||||
public void TestV1Get()
|
||||
{
|
||||
APICredentials creds = new APICredentials();
|
||||
creds.UserID = "testdoctor";
|
||||
creds.Password = "testdoctor";
|
||||
creds.PracticeId = "210";
|
||||
creds.APIid = "12345678";
|
||||
|
||||
APIConnection conn = new APIConnection("http://apipatientweb.azurewebsites.net/", creds);
|
||||
|
||||
string res = conn.SendPostRequestAsync("api/PWReferralTypes");
|
||||
Assert.AreEqual("\"1|Endo|2|Implant|3|Oral Surgery|4|Ortho|5|Pedo|6|Perio|7|Restore|8|Other \\n\"", res);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user