File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
metafacture-biblio/src/test/java/org/metafacture/biblio/marc21 Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change @@ -241,6 +241,21 @@ public void issue336_createRecordWithTopLevelLeader_dummy() {
241
241
assertEquals (expected , actual );
242
242
}
243
243
244
+ @ Test
245
+ public void issue548_createRecordWithTypeAttributeInRecordTagAndLeader () {
246
+ encoder .startRecord (RECORD_ID );
247
+ encoder .literal ("type" , "Bibliographic" );
248
+ encoder .startEntity (Marc21EventNames .LEADER_ENTITY );
249
+ encoder .literal (Marc21EventNames .LEADER_ENTITY , "dummy" );
250
+ encoder .endEntity ();
251
+ encoder .endRecord ();
252
+ encoder .closeStream ();
253
+ String expected = XML_DECLARATION + XML_ROOT_OPEN + "<marc:record type=\" Bibliographic\" >" +
254
+ "<marc:leader>dummy</marc:leader></marc:record>" + XML_MARC_COLLECTION_END_TAG ;
255
+ String actual = resultCollector .toString ();
256
+ assertEquals (expected , actual );
257
+ }
258
+
244
259
@ Test
245
260
public void issue336_createRecordWithTopLevelLeader_defaultMarc21Xml () {
246
261
issue336_createRecordWithTopLevelLeader (encoder , "00000naa a2200000uc 4500" );
You can’t perform that action at this time.
0 commit comments