예제 #1
0
 @Test
 public void binaryToStringTest() {
   OSimpleObject<byte[]> simpleObject =
       OSimpleObjects.create(EdmSimpleType.BINARY, VALUE.getBytes());
   String toString = simpleObject.toString();
   Assert.assertTrue(toString.contains(HEX_VALUE));
 }
예제 #2
0
 @Test
 public void parseNullProperty() throws Exception {
   for (EdmSimpleType<?> simpleType : EdmSimpleType.ALL) {
     OSimpleObject<?> simpleObject = OSimpleObjects.parse(simpleType, null);
     assertThat(simpleObject.getType(), is(simpleType.getClass()));
     assertThat(simpleObject.getValue(), nullValue());
   }
 }
예제 #3
0
 @Test
 public void stringToStringTest() {
   OSimpleObject<String> simpleObject = OSimpleObjects.create(EdmSimpleType.STRING, VALUE);
   String toString = simpleObject.toString();
   Assert.assertTrue(toString.contains(VALUE));
 }