use of org.springframework.cloud.gcp.data.spanner.core.convert.TestEntities.FaultyTestEntity in project spring-cloud-gcp by spring-cloud.
the class ConverterAwareMappingSpannerEntityWriterTests method writeIncompatibleTypeTest.
@Test
public void writeIncompatibleTypeTest() {
this.expectedEx.expect(SpannerDataException.class);
this.expectedEx.expectMessage("Unsupported mapping for type: " + "class org.springframework.cloud.gcp.data.spanner.core.convert.TestEntities$TestEntity");
FaultyTestEntity ft = new FaultyTestEntity();
ft.fieldWithUnsupportedType = new TestEntity();
WriteBuilder writeBuilder = Mutation.newInsertBuilder("faulty_test_table");
this.spannerEntityWriter.write(ft, writeBuilder::set);
}
Aggregations