mirror of
https://github.com/ZHANGTIANYAO1/teamspeak-music-bot.git
synced 2026-10-02 04:52:50 +08:00
fix: address Phase 1 review — union types, auto playedAt, ESM imports, gitignore config.json
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
9931d8b40d
commit
bc89c553b7
5 files changed
+15
-14
No files matched your search
@@ -1,5 +1,5 @@
|
||||
import { describe, it, expect, beforeEach, afterEach } from "vitest";
|
||||
import { createDatabase, type BotDatabase, type BotInstance } from "./database.js";
|
||||
import { createDatabase, type BotDatabase, type BotInstance, type PlayHistoryEntry } from "./database.js";
|
||||
|
||||
describe("database", () => {
|
||||
let botDb: BotDatabase;
|
||||
@@ -32,7 +32,6 @@ describe("database", () => {
|
||||
album: "Test Album",
|
||||
platform: "netease",
|
||||
coverUrl: "https://example.com/cover.jpg",
|
||||
playedAt: new Date().toISOString(),
|
||||
});
|
||||
|
||||
botDb.addPlayHistory({
|
||||
@@ -43,7 +42,6 @@ describe("database", () => {
|
||||
album: "Another Album",
|
||||
platform: "qq",
|
||||
coverUrl: "https://example.com/cover2.jpg",
|
||||
playedAt: new Date().toISOString(),
|
||||
});
|
||||
|
||||
const history = botDb.getPlayHistory("bot1", 10);
|
||||
|
||||
Reference in new issue
Block a user