mirror of
https://github.com/openclaw/openclaw.git
synced 2026-06-05 15:02:56 +00:00
test(msteams): add keyed store to file consent runtime stub
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
import fs from "node:fs";
|
||||
import os from "node:os";
|
||||
import path from "node:path";
|
||||
import type { OpenKeyedStoreOptions } from "openclaw/plugin-sdk/plugin-state-runtime";
|
||||
import { createPluginStateKeyedStoreForTests } from "openclaw/plugin-sdk/plugin-state-test-runtime";
|
||||
import { afterEach, beforeEach, describe, expect, it, vi } from "vitest";
|
||||
import type { PluginRuntime } from "../runtime-api.js";
|
||||
import { runMSTeamsFileConsentInvokeHandler } from "./file-consent-invoke.js";
|
||||
@@ -45,6 +47,8 @@ function createRuntimeStub(stateDir?: string): PluginRuntime {
|
||||
},
|
||||
},
|
||||
state: {
|
||||
openKeyedStore: (options: OpenKeyedStoreOptions) =>
|
||||
createPluginStateKeyedStoreForTests("msteams", options),
|
||||
resolveStateDir: (env?: NodeJS.ProcessEnv) => {
|
||||
const override = env?.OPENCLAW_STATE_DIR?.trim();
|
||||
if (override) {
|
||||
|
||||
Reference in New Issue
Block a user