Skip to content

Commit c3dff8b

Browse files
committedAug 16, 2024
Add debugging to migration test
1 parent 440df86 commit c3dff8b

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed
 

‎integration-tests/src/test/java/io/apicurio/tests/migration/DataMigrationIT.java

+11-4
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
import io.apicurio.registry.client.auth.VertXAuthFactory;
44
import io.apicurio.registry.rest.client.RegistryClient;
55
import io.apicurio.registry.rest.client.models.ArtifactReference;
6+
import io.apicurio.registry.rest.client.models.Error;
67
import io.apicurio.registry.types.RuleType;
78
import io.apicurio.registry.utils.tests.TestUtils;
89
import io.apicurio.tests.ApicurioRegistryBaseIT;
@@ -66,10 +67,16 @@ public void migrate() throws Exception {
6667
assertTrue(matchesReferencesV2V3(srcReferences, destReferences));
6768
}
6869
}
69-
assertEquals("SYNTAX_ONLY", dest.groups().byGroupId("migrateTest").artifacts().byArtifactId("avro-0")
70-
.rules().byRuleType(RuleType.VALIDITY.name()).get().getConfig());
71-
assertEquals("BACKWARD",
72-
dest.admin().rules().byRuleType(RuleType.COMPATIBILITY.name()).get().getConfig());
70+
try {
71+
assertEquals("SYNTAX_ONLY", dest.groups().byGroupId("migrateTest").artifacts().byArtifactId("avro-0")
72+
.rules().byRuleType(RuleType.VALIDITY.name()).get().getConfig());
73+
assertEquals("BACKWARD",
74+
dest.admin().rules().byRuleType(RuleType.COMPATIBILITY.name()).get().getConfig());
75+
} catch (Error e) {
76+
log.error("REST Client error: " + e.getMessageEscaped());
77+
log.error(" : " + e.getDetail());
78+
throw e;
79+
}
7380
}
7481

7582
public static class MigrateTestInitializer extends AbstractTestDataInitializer {

0 commit comments

Comments
 (0)