package.test.error.js Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of traverse Show documentation
Show all versions of traverse Show documentation
traverse and transform objects by visiting every node on a recursive walk
The newest version!
'use strict';
var test = require('tape');
var traverse = require('../');
test('traverse an Error', function (t) {
var obj = new Error('test');
var results = traverse(obj).map(function () {});
t.same(results, { message: 'test' });
t.end();
});