Code coverage report for jade\lib\nodes\code.js

Statements: 100% (10 / 10)      Branches: 100% (2 / 2)      Functions: 100% (1 / 1)      Lines: 100% (9 / 9)      Ignored: none     

All files » jade\lib\nodes\ » code.js
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26    1                       1 457 457 457 457       1 1   1
'use strict';
 
var Node = require('./node');
 
/**
 * Initialize a `Code` node with the given code `val`.
 * Code may also be optionally buffered and escaped.
 *
 * @param {String} val
 * @param {Boolean} buffer
 * @param {Boolean} escape
 * @api public
 */
 
var Code = module.exports = function Code(val, buffer, escape) {
  this.val = val;
  this.buffer = buffer;
  this.escape = escape;
  if (val.match(/^ *else/)) this.debug = false;
};
 
// Inherit from `Node`.
Code.prototype = Object.create(Node.prototype);
Code.prototype.constructor = Code;
 
Code.prototype.type = 'Code'; // prevent the minifiers removing this