web-apps/vendor/requirejs/tests/browsertests/noload/server.js
Maxim Kadushkin 741b10515d webapps added
2016-03-10 21:48:53 -03:00

27 lines
554 B
JavaScript

/*jslint strict: false*/
/*global require: false, console: false */
var http = require('http'),
host = '0.0.0.0',
port = 9320,
config;
http.createServer(function (req, res) {
req.on('end', function () {
var contents = '500 server error';
res.writeHead(500, {
'Content-Type': 'text/plain',
'Content-Length': contents.length
});
res.write(contents, 'utf8');
res.end();
});
}).listen(port, host);
console.log('Server running at http://' + host + ':' + port + '/');