public void TelementryInterval_CouldChangeTelementryInterval(string deviceTarget, string methodName, string payload, string expected) { string connectstring = "HostName=Ec-win20-iothubb.azure-devices.net;SharedAccessKeyName=iothubowner;SharedAccessKey=eSZmlrnE6XGEFfTVtMvUMBFAYkBqCPxsGkT8aw9uNQw="; var service = new Serviceclient(connectstring); var actual = service.InvokeMethod(deviceTarget, methodName, payload); Assert.Equal(expected, actual.Result.Status.ToString()); }
public void Test1() { string connectstring = "HostName=Ec-win20-iothubb.azure-devices.net;SharedAccessKeyName=iothubowner;SharedAccessKey=eSZmlrnE6XGEFfTVtMvUMBFAYkBqCPxsGkT8aw9uNQw="; var service = new Serviceclient(connectstring); var expected = "200"; var actual = service.InvokeMethod("DeviceApp1", "SetTelementryInterval", "10"); Assert.Equal(expected, actual.Result.Status.ToString()); }