mirror of
https://github.com/Termix-SSH/Termix.git
synced 2026-10-31 15:45:23 +00:00
feat: unify alerts into one plugin, channels, rules and inbox
This commit is contained in:
1 parent
fbe736bc20
commit
7c02daccf4
129 files changed
+20957
-2687
No files matched your search
@@ -175,6 +175,23 @@ describe("adopting the automation tables", () => {
|
||||
"idx_automation_runs_user",
|
||||
]);
|
||||
|
||||
// Channels moved to the alerts plugin, so a link may name a channel the
|
||||
// old table never had, and the old one's link is still there.
|
||||
expect(indexes(db, "p_automations_channels")).toEqual([
|
||||
"idx_automation_channels_pair",
|
||||
]);
|
||||
expect(
|
||||
db.sqlite.prepare("SELECT channel_id FROM p_automations_channels").all(),
|
||||
).toEqual([{ channel_id: 4 }]);
|
||||
db.sqlite
|
||||
.prepare(
|
||||
"INSERT INTO p_automations_channels (automation_id, channel_id) VALUES (7, 99)",
|
||||
)
|
||||
.run();
|
||||
db.sqlite
|
||||
.prepare("DELETE FROM p_automations_channels WHERE channel_id = 99")
|
||||
.run();
|
||||
|
||||
// The foreign keys followed the rename: deleting the automation still
|
||||
// takes its state, schedule, runs, steps and channel links with it.
|
||||
db.sqlite
|
||||
|
||||
Reference in new issue
Block a user