Build: Don't assume the browser environment; smoke test on Node w/ jsdom

Refs gh-1788
@timmywil We could also use `window.DOMParser` etc. which has the advantage that if jsdom ever gets support for that it starts to work.

In fact, `jsdom` already supports XMLHttpRequest. I'll modify the PR.