Search in sources :

Example 1 with QAddress

use of org.springframework.data.mongodb.repository.QAddress in project spring-data-mongodb by spring-projects.

the class SpringDataMongodbSerializerUnitTests method returnsEmptyStringIfNoPathExpressionIsGiven.

// DATAMONGO-376
@Test
public void returnsEmptyStringIfNoPathExpressionIsGiven() {
    QAddress address = QPerson.person.shippingAddresses.any();
    assertThat(serializer.getKeyForPath(address, address.getMetadata()), is(""));
}
Also used : QAddress(org.springframework.data.mongodb.repository.QAddress) Test(org.junit.Test)

Aggregations

Test (org.junit.Test)1 QAddress (org.springframework.data.mongodb.repository.QAddress)1