Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(URGENT) Escaped XML characters should remain escaped in XML output #130

Open
ronaldtse opened this issue Oct 30, 2024 · 0 comments
Open
Assignees
Labels
bug Something isn't working

Comments

@ronaldtse
Copy link
Contributor

From:

This seems to be a lutaml-model XML writing bug. It should always keep special characters in strings "escaped".

  1) Niso::Jats::Article with bmj_sample.xml behaves like a serializer round-trips with xml-c14
     Failure/Error: expect(output).to be_analogous_with(input)
     
       DIFF 1: expected node: <source>Continuity of care: report of a scoping exercise for
                   the national co-ordinating centre for NHS Service Delivery and
                   Organisation R (NCCSDO), Summer 2000</source>
               actual node  : <source>Continuity of care: report of a scoping exercise for
                   the national co-ordinating centre for NHS Service Delivery and
                   Organisation R&amp;D (NCCSDO), Summer 2000</source>
               diff from    : Continuity of care: report of a scoping exercise for the national co-ordinating centre for NHS Service Delivery and Organisation R (NCCSDO), Summer 2000
               diff to      : Continuity of care: report of a scoping exercise for the national co-ordinating centre for NHS Service Delivery and Organisation R&D (NCCSDO), Summer 2000
     Shared Example Group: "a serializer" called from ./spec/niso/jats/article_spec.rb:6
     # ./spec/support/shared_examples.rb:17:in `block (2 levels) in <top (required)>'

  2) Niso::Jats::Article with pnas_sample.xml behaves like a serializer round-trips with xml-c14
     Failure/Error: expect(output).to be_analogous_with(input)
     
       DIFF 1: expected node: <role degree-contribution="supporting" vocab="CRediT" vocab-identifier="http://credit.niso.org" vocab-term="Writing — Review &amp; Editing" vocab-term-identifier="http://credit.niso.org/contributor-roles/writing-review-editing/">Writing
                   — Review  Editing</role>
               actual node  : <role degree-contribution="supporting" vocab="CRediT" vocab-identifier="http://credit.niso.org" vocab-term="Writing — Review &amp; Editing" vocab-term-identifier="http://credit.niso.org/contributor-roles/writing-review-editing/">Writing
                   — Review &amp; Editing</role>
               diff from    : Writing — Review Editing
               diff to      : Writing — Review & Editing
@ronaldtse ronaldtse added the bug Something isn't working label Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants