swarm-ui: the setup assistant shows when ruth is declared destroyed
This commit is contained in:
parent
bbc2a83771
commit
1ee481c0b1
1 changed files with 25 additions and 6 deletions
|
|
@ -33,6 +33,20 @@ test("a roster with ruth means she is not missing", async () => {
|
|||
);
|
||||
});
|
||||
|
||||
test("a ruth declared destroyed is missing; a stopped or paused one is not", async () => {
|
||||
assert.equal(
|
||||
await ruthIsMissing(answering([{ name: "ruth", wanted: "destroyed" }])),
|
||||
true,
|
||||
);
|
||||
for (const wanted of ["up", "offline", "paused", null, undefined]) {
|
||||
assert.equal(
|
||||
await ruthIsMissing(answering([{ name: "ruth", wanted }])),
|
||||
false,
|
||||
String(wanted),
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
test("anything but a clear answer is not missing", async () => {
|
||||
assert.equal(await ruthIsMissing(answering([], false)), false);
|
||||
assert.equal(await ruthIsMissing(answering({ not: "a list" })), false);
|
||||
|
|
|
|||
Loading…
Reference in a new issue