use of com.microsoft.azure.sdk.iot.device.DeviceTwin.DeviceMethodData in project azure-iot-sdk-java by Azure.
the class DeviceMethodDataTest method setStatusSets.
/*
**Tests_SRS_DEVICEMETHODDATA_25_007: [**The method shall set the status.**]**
*/
@Test
public void setStatusSets() {
// arrange
DeviceMethodData testData = new DeviceMethodData(0, "testMessage");
// act
testData.setStatus(200);
// assert
int testStatus = testData.getStatus();
assertEquals(200, testStatus);
}
use of com.microsoft.azure.sdk.iot.device.DeviceTwin.DeviceMethodData in project azure-iot-sdk-java by Azure.
the class DeviceMethodDataTest method getResponseMessageGets.
/*
**Tests_SRS_DEVICEMETHODDATA_25_004: [**This method shall return the response message previously set.**]**
*/
@Test
public void getResponseMessageGets() {
// arrange
DeviceMethodData testData = new DeviceMethodData(0, "testMessage");
// act
String testResponse = testData.getResponseMessage();
// assert
assertEquals(testResponse, "testMessage");
}
Aggregations