npm.io
0.0.4 • Published 9 years ago

stp

Licence
MIT
Version
0.0.4
Deps
0
Vulns
0
Weekly
0
describe('stp', function() {

  it('compile', function() {
    var fn = stp("hello ${name}");
    assert.equal(typeof fn, 'function');
    var rs = fn({ name: "word" });
    assert.equal(rs, 'hello word');
  });

  it('parse', function() {
    var rs = stp("hello ${name}", { name: "word" });
    assert.equal(rs, 'hello word');
  });

});

Keywords