From 0e713e7482b249bec4ee413ace69731045c5290f Mon Sep 17 00:00:00 2001 From: Ryan Dahl Date: Thu, 27 May 2010 16:49:21 -0700 Subject: [PATCH] :%s/8000/PORT/g for a few tests --- test/simple/test-http-set-timeout.js | 6 +++--- test/simple/test-http-write-empty-string.js | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/test/simple/test-http-set-timeout.js b/test/simple/test-http-set-timeout.js index 0bc816b00a..2725688ff1 100644 --- a/test/simple/test-http-set-timeout.js +++ b/test/simple/test-http-set-timeout.js @@ -11,17 +11,17 @@ server = http.createServer(function (req, res) { server.close(); }); }); -server.listen(8000); +server.listen(PORT); server.addListener('listening', function () { - sys.puts('Server running at http://127.0.0.1:8000/'); + sys.puts('Server running at http://127.0.0.1:'+PORT+'/'); errorTimer =setTimeout(function () { throw new Error('Timeout was not sucessful'); }, 2000); - http.cat('http://localhost:8000/', 'utf8', function (err, content) { + http.cat('http://localhost:'+PORT+'/', 'utf8', function (err, content) { clearTimeout(errorTimer); sys.puts('HTTP REQUEST COMPLETE (this is good)'); }); diff --git a/test/simple/test-http-write-empty-string.js b/test/simple/test-http-write-empty-string.js index 8a743c66e7..a3498fbf74 100644 --- a/test/simple/test-http-write-empty-string.js +++ b/test/simple/test-http-write-empty-string.js @@ -1,4 +1,5 @@ -PORT = 8000; +require('../common'); + sys = require('sys'); http = require('http'); assert = require('assert');