use of com.microsoft.azure.sdk.iot.service.Tools in project azure-iot-sdk-java by Azure.
the class ToolsTest method isNullOrWhiteSpace_input_white_space.
// Tests_SRS_SERVICE_SDK_JAVA_TOOLS_12_005: [The function shall call the isNullOrEmpty function and return with it’s return value]
@Test
public void isNullOrWhiteSpace_input_white_space() {
// Arrange
String value = " ";
Boolean expResult = true;
new Expectations() {
Tools tools;
{
tools.isNullOrEmpty(anyString);
}
};
// Act
Boolean result = Tools.isNullOrWhiteSpace(value);
// Assert
assertEquals(expResult, result);
}
use of com.microsoft.azure.sdk.iot.service.Tools in project azure-iot-sdk-java by Azure.
the class ToolsTest method isNullOrWhiteSpace_input_white_spaces.
// Tests_SRS_SERVICE_SDK_JAVA_TOOLS_12_005: [The function shall call the isNullOrEmpty function and return with it’s return value]
@Test
public void isNullOrWhiteSpace_input_white_spaces() {
// Arrange
String value = " ";
Boolean expResult = true;
new Expectations() {
Tools tools;
{
tools.isNullOrEmpty(anyString);
}
};
// Act
Boolean result = Tools.isNullOrWhiteSpace(value);
// Assert
assertEquals(expResult, result);
}
use of com.microsoft.azure.sdk.iot.service.Tools in project azure-iot-sdk-java by Azure.
the class ToolsTest method isNullOrWhiteSpace_not_empty.
// Tests_SRS_SERVICE_SDK_JAVA_TOOLS_12_005: [The function shall call the isNullOrEmpty function and return with it’s return value]
@Test
public void isNullOrWhiteSpace_not_empty() {
// Arrange
String value = "XXX";
Boolean expResult = false;
new Expectations() {
Tools tools;
{
tools.isNullOrEmpty(anyString);
}
};
// Act
Boolean result = Tools.isNullOrWhiteSpace(value);
// Assert
assertEquals(expResult, result);
}
Aggregations