@@ -52,8 +52,8 @@ public void cleanArtifacts() throws Exception {
52
52
53
53
@ Test
54
54
public void testConfiguration () throws Exception {
55
- String groupId = TestUtils .generateGroupId ();
56
- String topic = TestUtils .generateArtifactId ();
55
+ String groupId = "ns_" + TestUtils .generateGroupId (). replace ( "-" , "_" );
56
+ String topic = "topic-" + TestUtils .generateArtifactId (). replace ( "-" , "_" );
57
57
String recordName = "myrecord4" ;
58
58
AvroGenericRecordSchemaFactory schemaFactory = new AvroGenericRecordSchemaFactory (groupId , recordName ,
59
59
List .of ("bar" ));
@@ -108,7 +108,7 @@ public void testAvroIntDefaultValue() throws Exception {
108
108
Struct struct = new Struct (sc );
109
109
struct .put ("int16Test" , (short ) 3 );
110
110
111
- String subject = TestUtils .generateArtifactId ();
111
+ String subject = "subj_" + TestUtils .generateArtifactId (). replace ( "-" , "_" );
112
112
113
113
byte [] bytes = converter .fromConnectData (subject , sc , struct );
114
114
@@ -153,7 +153,7 @@ public void testAvroBytesDefaultValue() throws Exception {
153
153
154
154
struct .put ("bytesTest" , "testingBytes" .getBytes ());
155
155
156
- String subject = TestUtils .generateArtifactId ();
156
+ String subject = "subj_" + TestUtils .generateArtifactId (). replace ( "-" , "_" );
157
157
158
158
byte [] bytes = converter .fromConnectData (subject , sc , struct );
159
159
@@ -187,7 +187,7 @@ public void testAvro() throws Exception {
187
187
Struct struct = new Struct (sc );
188
188
struct .put ("bar" , "somebar" );
189
189
190
- String subject = TestUtils .generateArtifactId ();
190
+ String subject = "subj_" + TestUtils .generateArtifactId (). replace ( "-" , "_" );
191
191
192
192
byte [] bytes = converter .fromConnectData (subject , sc , struct );
193
193
@@ -242,7 +242,7 @@ public void testConnectStruct() throws Exception {
242
242
envelopeStruct .put ("ts_ms" , 1638362438000L ); // Replace with the actual timestamp
243
243
envelopeStruct .put ("transaction" , buildTransactionStruct ());
244
244
245
- String subject = TestUtils .generateArtifactId ();
245
+ String subject = "subj_" + TestUtils .generateArtifactId (). replace ( "-" , "_" );
246
246
247
247
byte [] bytes = converter .fromConnectData (subject , envelopeSchema , envelopeStruct );
248
248
0 commit comments