EdmSimpleType edmType = EasyMock.createMock(EdmSimpleType.class);
EasyMock.expect(edmType.getKind()).andStubReturn(EdmTypeKind.SIMPLE);
Facets facets = new Facets().setNullable(false);
try {
EasyMock.expect(edmType.valueToString(new Integer(2), EdmLiteralKind.URI, facets)).andStubReturn("2");
EasyMock.expect(edmType.valueToString(new Integer(2), EdmLiteralKind.DEFAULT, facets)).andStubReturn("2");
} catch (EdmSimpleTypeException e1) {
fail("There is an exception in mocking EdmType object " + e1.getMessage());
}
EasyMock.replay(edmType);
EdmProperty edmProperty = EasyMock.createMock(EdmProperty.class);