fix(web): narrow natal-minute consultation mode for the production build
BUG-341 added declared_birth_window, but the natal-minute helper still returned boolean, so next build could not pass that mode into serverChartFromProfile. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -13,6 +13,11 @@ import { getGeneralJyotishAgent } from "../src/mastra/index.ts";
|
||||
import type { ResolvedLanguageModel } from "../src/mastra/model.ts";
|
||||
|
||||
test("general-no-birth-time is an explicit server mode that never runs a chart workflow", () => {
|
||||
const source = readFileSync(new URL("../src/lib/consultation-birth-time-mode.ts", import.meta.url), "utf8");
|
||||
assert.match(
|
||||
source,
|
||||
/export function isNatalMinuteConsultationMode\(\s*mode: ConsultationBirthTimeMode,\s*\): mode is NatalMinuteConsultationMode/,
|
||||
);
|
||||
assert.equal(consultationBirthTimeModeSchema.safeParse("verified_chart").success, true);
|
||||
assert.equal(consultationBirthTimeModeSchema.safeParse("unverified_birth_time").success, true);
|
||||
assert.equal(consultationBirthTimeModeSchema.safeParse("declared_birth_window").success, true);
|
||||
|
||||
Reference in New Issue
Block a user