adda0569e0
Allows for testing node, browser, and precompiled modes in the node tests. Also reorganizes the qunit spec file to provide better organization.
14 lines
388 B
JavaScript
14 lines
388 B
JavaScript
require('./common');
|
|
|
|
global.Handlebars = require('../../dist/handlebars');
|
|
|
|
global.CompilerContext = {
|
|
compile: function(template, options) {
|
|
var templateSpec = Handlebars.precompile(template, options);
|
|
return Handlebars.template(eval('(' + templateSpec + ')'));
|
|
},
|
|
compileWithPartial: function(template, options) {
|
|
return Handlebars.compile(template, options);
|
|
}
|
|
};
|