Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.junit.jupiter.api.Assertions.assertInstanceOf;
import static org.junit.jupiter.api.Assertions.assertNotNull;
import static org.junit.jupiter.api.Assumptions.assumeTrue;

import java.io.ByteArrayOutputStream;
import java.io.IOException;
Expand Down Expand Up @@ -133,6 +134,8 @@ void genericDataModelIgnoresJavaClassPropWithString() throws IOException {
*/
@Test
void specificDataModelUsesJavaClassProp() throws IOException {
assumeTrue(SpecificData.get().isFastReaderEnabled(),
"java-class conversion is only applied on the fast-reader path");
GenericRecord result = roundTrip(RECORD_WITH_NULLABLE_CLASS_PROP, SpecificData.get());

assertNotNull(result);
Expand All @@ -149,6 +152,8 @@ void specificDataModelUsesJavaClassProp() throws IOException {
*/
@Test
void specificDataModelUsesJavaClassPropWithDirectString() throws IOException {
assumeTrue(SpecificData.get().isFastReaderEnabled(),
"java-class conversion is only applied on the fast-reader path");
GenericRecord result = roundTrip(RECORD_WITH_CLASS_PROP, SpecificData.get());

assertNotNull(result);
Expand Down Expand Up @@ -189,6 +194,8 @@ void genericDataModelIgnoresJavaKeyClassPropWithMap() throws IOException {
*/
@Test
void specificDataModelUsesJavaKeyClassProp() throws IOException {
assumeTrue(SpecificData.get().isFastReaderEnabled(),
"java-key-class conversion is only applied on the fast-reader path");
GenericRecord result = roundTrip(RECORD_WITH_MAP_KEY_CLASS_PROP, SpecificData.get());

assertNotNull(result);
Expand Down
Loading