You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
418 B

var s = node.http.createServer(function (req, res) {
var body = "exports.A = function() { return 'A';}";
res.sendHeader(200, [
["Content-Length", body.length],
["Content-Type", "text/plain"]
]);
res.sendBody(body);
res.finish();
});
s.listen(8000);
node.mixin(require("../common.js"));
var a = require("http://localhost:8000/")
15 years ago
assertInstanceof(a.A, Function);
assertEquals("A", a.A());
s.close();