Skip to content

Check XML files for well-formedness #1271

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

Merged
merged 1 commit into from
Nov 27, 2015
Merged

Check XML files for well-formedness #1271

merged 1 commit into from
Nov 27, 2015

Conversation

teobugslayer
Copy link
Contributor

Check XML files for well-formedness. No validation is performed. The check should happen at least on build and livesync.

Whenever an invalid XML file is found:

  • for livesync --watch operation, warn the user, but do not break the CLI
  • for every other operation, abort it

Implementation detail: it happens actually on prepare.
See #1272

@ns-bot
Copy link

ns-bot commented Nov 27, 2015

Test FAILed.

let xmlHasErrors = false;
let DomParser = require("xmldom").DOMParser;
sourceFiles
.filter(file => _.endsWith(file, ".xml"))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe path.ext

@rosen-vladimirov
Copy link
Contributor

Nice one! 👍

@ns-bot
Copy link

ns-bot commented Nov 27, 2015

Test PASSed.

teobugslayer added a commit that referenced this pull request Nov 27, 2015
Check XML files for well-formedness
@teobugslayer teobugslayer merged commit afbbc92 into release Nov 27, 2015
@teobugslayer teobugslayer deleted the totev/xml-verify branch November 27, 2015 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants