inveniosoftware / dojson

Simple pythonic JSON to JSON converter.
https://dojson.readthedocs.io
Other
10 stars 29 forks source link

tests: demo MARC21 data #75

Closed jirikuncar closed 8 years ago

jirikuncar commented 8 years ago

@Kennethhole you can play a bit with following example compiled from your https://github.com/inveniosoftware/dojson/issues/39#issuecomment-179382406.

Check out this pull-request locally [1], run pip install -e . and then you can try following commands:

$ dojson -i tests/demo_marc21_full.xml -l marcxml -d marcxml do marc21 do to_marc21 > test.xml
$ xmllint --format test.xml | diff - tests/demo_marc21_full.xml

You can add more fields to tests/demo_marc21_full.xml, but just don't forget to xmllint the file (usual problem with &). When you have new fields in the file check first that all fields are known by running dojson -i tests/demo_marc21_full.xml -l marcxml missing marc21.

[1] https://help.github.com/articles/checking-out-pull-requests-locally/

jirikuncar commented 8 years ago

Superseded by #76