LearnBoost/juice — pull request #13 by cbumgard (2012-12-13 22:33:08+00:00)
Title: New regression tests; fixed existing tests; bumped version

- Added a regression test for the previous media rule fix
- Discovered all existing test cases failed because jsdom.html() -- called by /lib/utils/jsdom() -- wrapped all those /test/cases/*.out files with \\ and \\ tags which wasn't expected
- Fixed (?) those test cases by adding missing html & body tags
- Added a regression test for this case as well (/test/cases/jsdom.*)
- Bumped the version to 0.0.7 so a new npm can be published and used by projects like mine that depend on it :)

FYI here's the code in **jsdom** that appears to add the html & body tags:

exports.html = function(html, level, options) {
html += '';

// TODO: cache a regex and use it here instead
// or make the parser handle it
var htmlLowered = html.toLowerCase();

// body
if (!~htmlLowered.indexOf('';
}

// html
if (!~htmlLowered.indexOf('';
}
return exports.jsdom(html, level, options);
};