mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-29 14:45:24 +00:00
fix: retry failed or blocked plugins on restart instead of leaving them disabled
This commit is contained in:
1 parent
b6bb3ffc73
commit
27819c477c
3 files changed
+55
-13
No files matched your search
@@ -0,0 +1,15 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
import { startablePluginIds } from "../../plugins/boot-state.js";
|
||||
|
||||
describe("startablePluginIds", () => {
|
||||
it("starts enabled plugins and retries ones that failed or were blocked", () => {
|
||||
const ids = startablePluginIds([
|
||||
{ id: "a", state: "enabled" },
|
||||
{ id: "b", state: "failed" },
|
||||
{ id: "c", state: "blocked" },
|
||||
{ id: "d", state: "disabled" },
|
||||
{ id: "e", state: "pending" },
|
||||
]);
|
||||
expect([...ids].sort()).toEqual(["a", "b", "c"]);
|
||||
});
|
||||
});
|
||||
Reference in new issue
Block a user