修正追踪初始化竞态与浏览器验证
This commit is contained in:
@@ -18,7 +18,7 @@ const samplesDir =
|
||||
const reportDir =
|
||||
process.env.GEO_SAMPLE_REPORT_DIR ??
|
||||
join(repoRoot, "test-results", "geo-sample-flow", "manual");
|
||||
const baseURL = process.env.GEO_SAMPLE_BASE_URL ?? "http://127.0.0.1:3000";
|
||||
const baseURL = process.env.GEO_SAMPLE_BASE_URL ?? "http://localhost:3000";
|
||||
const apiAccessKey = process.env.API_ACCESS_KEY ?? "local-dev-key";
|
||||
const timeoutMs = Number(process.env.GEO_SAMPLE_TIMEOUT_MS ?? "600000");
|
||||
const filter = process.env.GEO_SAMPLE_FILTER;
|
||||
@@ -26,8 +26,13 @@ const limit = Number(process.env.GEO_SAMPLE_LIMIT ?? "0");
|
||||
|
||||
const loaded = loadArticleSamples(samplesDir);
|
||||
const selectedSamples = selectSamples(loaded.valid, filter, limit);
|
||||
const provider = process.env.LLM_PROVIDER ?? "deepseek";
|
||||
const hasLiveLlmCredentials = provider === "openai"
|
||||
? Boolean(process.env.OPENAI_API_KEY)
|
||||
: Boolean(process.env.DEEPSEEK_API_KEY);
|
||||
|
||||
test.describe("GEO sample article live E2E flow", () => {
|
||||
test.skip(!hasLiveLlmCredentials, "需要真实 LLM 提供商密钥");
|
||||
test.beforeAll(() => {
|
||||
mkdirSync(reportDir, { recursive: true });
|
||||
writeFileSync(
|
||||
|
||||
Reference in New Issue
Block a user