DATACMNS-380 - MappingContext.getPersistentPropertyPath(…) now throws MappingException.

This commit is contained in:
Oliver Gierke
2013-10-10 13:42:33 +02:00
parent 048394690f
commit 1b3d9ed2c4
2 changed files with 9 additions and 1 deletions

View File

@@ -185,6 +185,14 @@ public class AbstractMappingContextUnitTests {
assertThat(path.getLeafProperty().getName(), is("name"));
}
/**
* @see DATACMNS-380
*/
@Test(expected = MappingException.class)
public void rejectsInvalidPropertyReferenceWithMappingException() {
context.getPersistentPropertyPath("foo", Sample.class);
}
class Person {
String name;
}