test(FN-4313): complete Step 2 — add project engine id accessor
Fusion-Task-Id: FN-4313 Fusion-Task-Lineage: 36b8aad3-20f4-475b-9b0f-63e5458d1b91
This commit is contained in:
@@ -306,6 +306,24 @@ describe("ProjectEngine notification ownership wiring", () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe("ProjectEngine accessors", () => {
|
||||
it("returns configured project id", () => {
|
||||
const engine = new ProjectEngine(
|
||||
{
|
||||
projectId: "proj_accessor",
|
||||
workingDirectory: "/tmp/proj_accessor",
|
||||
isolationMode: "in-process",
|
||||
maxConcurrent: 2,
|
||||
maxWorktrees: 2,
|
||||
},
|
||||
{} as never,
|
||||
{ skipNotifier: true },
|
||||
);
|
||||
|
||||
expect(engine.getProjectId()).toBe("proj_accessor");
|
||||
});
|
||||
});
|
||||
|
||||
describe("ProjectEngine PR monitoring wiring", () => {
|
||||
it("wires runtime scheduler PR monitoring with closed-PR follow-up handler", async () => {
|
||||
const { store } = createMockStore(baseSettings);
|
||||
|
||||
@@ -626,6 +626,11 @@ export class ProjectEngine {
|
||||
return this.config.workingDirectory;
|
||||
}
|
||||
|
||||
/** Get the project id. */
|
||||
getProjectId(): string {
|
||||
return this.config.projectId;
|
||||
}
|
||||
|
||||
/** Get the PrMonitor (if initialized). */
|
||||
getPrMonitor(): PrMonitor | undefined {
|
||||
return this.prMonitor;
|
||||
|
||||
Reference in New Issue
Block a user