diff --git a/graph-ui/src/architecture/BehaviorJourney.test.tsx b/graph-ui/src/architecture/BehaviorJourney.test.tsx index b4b065439..031402764 100644 --- a/graph-ui/src/architecture/BehaviorJourney.test.tsx +++ b/graph-ui/src/architecture/BehaviorJourney.test.tsx @@ -110,6 +110,14 @@ describe('behavior journeys', () => { await render(data, { data: undefined, pending: false, error: 'Snapshot changed.' }); expect(container.querySelector('[data-scene]')).toBeNull(); expect(container.textContent).toContain('Snapshot changed.'); }); + it('shows the operation the journey opened with in the Start field, not "Choose an operation"', async () => { + // Without a requested entry the journey falls back to the first entry point (Django: main in manage.py-tpl). + await render(fixture(), { entryId: undefined }); + const start = container.querySelector('[aria-label="Behavior entry point"]')!; + expect(container.querySelector('.behavior-heading h2')?.textContent).toBe('What can operation1 call?'); + expect(start.value).toBe('1'); + expect(start.selectedOptions[0]?.textContent).toBe('operation1 · src/part1.ts'); + }); it('pages only real edges and component lanes within the selected path window', () => { const scene = behaviorJourney(fixture(), { entryId: 1, targetId: 9 }).scene; const page = journeyPage(scene, 6), ids = new Set(page.nodes.map(node => node.id)); diff --git a/graph-ui/src/architecture/BehaviorJourney.tsx b/graph-ui/src/architecture/BehaviorJourney.tsx index 89e873665..83d70431f 100644 --- a/graph-ui/src/architecture/BehaviorJourney.tsx +++ b/graph-ui/src/architecture/BehaviorJourney.tsx @@ -134,7 +134,8 @@ export default function BehaviorJourney({ project, generation, data, entries, ta

{path ? 'Follow one recorded call chain across the parts it touches.' : 'Choose a starting operation. Explore its calls, or follow a path to a destination.'}

-