mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-09 13:07:39 +00:00
test: finish readonly fixture compatibility for CI check
This commit is contained in:
committed by
Peter Steinberger
parent
c7c047287e
commit
828f4e18e0
@@ -595,16 +595,20 @@ describe("sendMessageTelegram", () => {
|
||||
fileName: "video.mp4",
|
||||
});
|
||||
|
||||
const opts = {
|
||||
const opts: Parameters<typeof sendMessageTelegram>[2] = {
|
||||
token: "tok",
|
||||
api,
|
||||
mediaUrl: "https://example.com/video.mp4",
|
||||
asVideoNote: true,
|
||||
...testCase.options,
|
||||
...("replyToMessageId" in testCase.options
|
||||
? { replyToMessageId: testCase.options.replyToMessageId }
|
||||
: {}),
|
||||
...("buttons" in testCase.options
|
||||
? {
|
||||
buttons: testCase.options.buttons.map((row) => row.map((button) => ({ ...button }))),
|
||||
}
|
||||
: {}),
|
||||
};
|
||||
if (opts.buttons) {
|
||||
opts.buttons = opts.buttons.map((row) => [...row]);
|
||||
}
|
||||
|
||||
await sendMessageTelegram(chatId, testCase.text, opts);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user