error.js.disabled 280 Bytes RawBlameHistoryPermalink 1 2 3 4 5 6 7 8 9 10 11 12 var Buffer = require('buffer').Buffer var test = require('tape') var http = require('../..') test('error handling', function (t) { var req = http.get('https://0.0.0.0:0/fail.txt') req.on('error', function (err) { t.ok(err && ('message' in err), 'got error') t.end() }) })