mirror of
https://github.com/clusterio/clusterio.git
synced 2026-11-17 23:33:12 +09:00
Set status to unknown on slave disconnect
Change the instance status to unknown if the slave it's connected to is disconnected rather than leaving them at their previous state indefinitely.
This commit is contained in:
1 parent
c9ae964eee
commit
c59267d5ee
3 files changed
+21
-2
No files matched your search
@@ -88,6 +88,9 @@ describe("Integration of Clusterio", function() {
|
||||
slaveProcess = await spawn(
|
||||
"alt-slave:", `node ../../packages/slave run --config ${config}`, /Started slave/
|
||||
);
|
||||
// Add instance to test the unknown status afterwards
|
||||
await execCtl("instance create alt-test --id 99");
|
||||
await execCtl("instance assign alt-test 5");
|
||||
} finally {
|
||||
if (slaveProcess) {
|
||||
slaveProcess.kill("SIGINT");
|
||||
@@ -524,7 +527,7 @@ describe("Integration of Clusterio", function() {
|
||||
describe("instanceUpdateEventHandler()", function() {
|
||||
it("should have triggered for the previous instance status updates", function() {
|
||||
let statusesToCheck = new Set([
|
||||
"unassigned", "stopped", "creating_save", "exporting_data",
|
||||
"unassigned", "unknown", "stopped", "creating_save", "exporting_data",
|
||||
"starting", "running", "stopping", "deleted",
|
||||
]);
|
||||
let statusesNotSeen = new Set(statusesToCheck);
|
||||
|
||||
Reference in new issue
Block a user