mirror of
https://github.com/azures04/crafatar.git
synced 2026-03-21 23:41:18 +01:00
Test valid inputs for all paths
This commit is contained in:
parent
9bebaff48e
commit
c925082f7f
@ -92,7 +92,7 @@ var exp = {};
|
||||
exp.boot = function(callback) {
|
||||
var port = process.env.PORT || 3000;
|
||||
var bind_ip = process.env.BIND || "127.0.0.1";
|
||||
console.log("Server running on http://" + bind_ip + ":" + port + "/");
|
||||
logging.log("Server running on http://" + bind_ip + ":" + port + "/");
|
||||
server = http.createServer(requestHandler).listen(port, bind_ip, function() {
|
||||
callback();
|
||||
});
|
||||
|
||||
@ -246,6 +246,13 @@ describe("Server", function() {
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
it("should return a 200 (valid input)", function(done) {
|
||||
request.get("http://localhost:3000/" + location + "/Jake0oo0", function(error, res, body) {
|
||||
assert.equal(200, res.statusCode);
|
||||
done();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
// testing all paths for default images
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user