All files / marshallers string.js

100% Statements 10/10
75% Branches 3/4
100% Functions 2/2
100% Lines 8/8

Press n or j to go to the next uncovered block, b, p or k for the previous block.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 151x     100x 100x 100x   100x 464x 464x     100x    
module.exports = {
  name: 'string',
  desc: 'applies Object.prototype.toString to the input and adds newlines.',
  func: ({}) => values => {
    let str   = ''
    const err = []
 
    for (let index = 0; index < values.length; index++) {
      const value = values[index]
      Eif (typeof value !== 'undefined' && value !== null) str += value.toString() + '\n'
    }
 
    return {err, str}
  }
}