mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-22 00:13:12 +09:00
Partially fixed broken web API test, removed old endpoint
This commit is contained in:
1 parent
936600c98b
commit
f6afa488d1
3 files changed
+1
-15
No files matched your search
@@ -755,6 +755,7 @@ if(args.masterPort || config.masterPort){
|
|||||||
server.listen(args.masterPort || config.masterPort || 8080, function () {
|
server.listen(args.masterPort || config.masterPort || 8080, function () {
|
||||||
console.log("Listening on port %s...", server.address().port);
|
console.log("Listening on port %s...", server.address().port);
|
||||||
});
|
});
|
||||||
|
module.exports = server;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Websockets for remoteMap */
|
/* Websockets for remoteMap */
|
||||||
@@ -985,5 +986,4 @@ async function getPlugins(){
|
|||||||
return plugins;
|
return plugins;
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = app;
|
|
||||||
})();
|
})();
|
||||||
@@ -76,17 +76,6 @@ describe('Master server endpoint testing', function() {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
it("sends some HTML when accessing /remoteMap",function(done){
|
|
||||||
this.timeout(6000);
|
|
||||||
request(app).get("/remoteMap").end(function(err,res){
|
|
||||||
assert.equal(res.statusCode, 200);
|
|
||||||
validateHTML(res.text).then(result => {
|
|
||||||
// there should be 1 error regarding complaining about me using ES6 modules before they are fully supported
|
|
||||||
assert(result.messages.length === 2, "there are HTML errors on the page, please fix: "+JSON.stringify(result.messages));
|
|
||||||
done();
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
});
|
||||||
let persistentMaster = request(app);
|
let persistentMaster = request(app);
|
||||||
describe("#POST /api/place", function(){
|
describe("#POST /api/place", function(){
|
||||||
|
|||||||
@@ -11,7 +11,4 @@ module.exports = function(app) {
|
|||||||
app.get("/nodeDetails", function(req, res) {
|
app.get("/nodeDetails", function(req, res) {
|
||||||
res.render("nodeDetails");
|
res.render("nodeDetails");
|
||||||
});
|
});
|
||||||
app.get("/remoteMap", function(req, res) {
|
|
||||||
res.render("remoteMap");
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
Reference in new issue
Block a user