1#!/usr/bin/env node 2 3var fs = require('fs'); 4 5require('unit-http').createServer(function (req, res) { 6 res.write('blah'); 7 8 Promise.resolve().then(() => { 9 res.end(); 10 }); 11 12 req.on('data', (data) => { 13 fs.appendFile('callback', '', function() {}); 14 }); 15 16}).listen(7080); 17