mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-24 03:15:46 -06:00
fix(qa): expect Telegram authorization rejection
(cherry picked from commit 606a5b32b1)
This commit is contained in:
@@ -700,7 +700,10 @@ describe("telegram live qa runtime", () => {
|
||||
).buildRun("sut_bot").steps;
|
||||
expect(repeatedSteps[0]?.driverGroupAuthorization).toBe("deny");
|
||||
expect(repeatedSteps[0]?.input).toBe("/status@sut_bot");
|
||||
expect(repeatedSteps[0]?.expectReply).toBe(false);
|
||||
expect(repeatedSteps[0]?.expectReply).toBe(true);
|
||||
expect(repeatedSteps[0]?.expectedTextIncludes).toEqual([
|
||||
"You are not authorized to use this command.",
|
||||
]);
|
||||
expect(repeatedSteps[1]?.driverGroupAuthorization).toBe("allow");
|
||||
expect(repeatedSteps[1]?.input).toBe("/status@sut_bot");
|
||||
expect(repeatedSteps[1]?.expectReply).toBe(true);
|
||||
|
||||
@@ -332,8 +332,9 @@ const TELEGRAM_QA_SCENARIOS: TelegramQaScenarioDefinition[] = [
|
||||
const steps = [
|
||||
{
|
||||
driverGroupAuthorization: "deny",
|
||||
expectReply: false,
|
||||
expectReply: true,
|
||||
input: `/status@${sutUsername}`,
|
||||
expectedTextIncludes: ["You are not authorized to use this command."],
|
||||
timeoutMs: 8_000,
|
||||
},
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user