@@ -119,53 +119,34 @@ describe.each(ENGINES)('Phase 8.5 CHA dispatch (%s)', (engine) => {
119119 } ) ;
120120
121121 // ── this-dispatch ──────────────────────────────────────────────────────
122- // The WASM path resolves `this.prepare()` through the class hierarchy via
123- // the inline CHA dispatch in buildFileCallEdges.
124- //
125- // The native orchestrator path does not persist raw call sites (with receiver
126- // info) to the DB after the Rust pipeline runs, so this-dispatch and
127- // super-dispatch cannot be resolved via runPostNativeCha.
128- // Tracked as a native accuracy gap in issue #1326.
129122
130- if ( engine === 'native' ) {
131- it . todo (
132- 'this-dispatch: emits ConcreteWorker.doWork → ConcreteWorker.prepare (native gap #1326)' ,
123+ it ( 'this-dispatch: emits ConcreteWorker.doWork → ConcreteWorker.prepare' , ( ) => {
124+ const edge = callEdges . find (
125+ ( e ) =>
126+ e . caller_name === 'ConcreteWorker.doWork' &&
127+ e . callee_name === 'ConcreteWorker.prepare' &&
128+ e . callee_file === 'ConcreteWorker.ts' ,
133129 ) ;
134- } else {
135- it ( 'this-dispatch: emits ConcreteWorker.doWork → ConcreteWorker.prepare' , ( ) => {
136- const edge = callEdges . find (
137- ( e ) =>
138- e . caller_name === 'ConcreteWorker.doWork' &&
139- e . callee_name === 'ConcreteWorker.prepare' &&
140- e . callee_file === 'ConcreteWorker.ts' ,
141- ) ;
142- expect (
143- edge ,
144- `Expected ConcreteWorker.doWork → ConcreteWorker.prepare edge (this-dispatch).\nActual edges:\n${ JSON . stringify ( callEdges , null , 2 ) } ` ,
145- ) . toBeDefined ( ) ;
146- } ) ;
147- }
130+ expect (
131+ edge ,
132+ `Expected ConcreteWorker.doWork → ConcreteWorker.prepare edge (this-dispatch).\nActual edges:\n${ JSON . stringify ( callEdges , null , 2 ) } ` ,
133+ ) . toBeDefined ( ) ;
134+ } ) ;
148135
149136 // ── super-dispatch ─────────────────────────────────────────────────────
150- // Same native gap: super.speak() requires raw call-site receiver info not
151- // persisted to the DB by the Rust pipeline. See issue #1326.
152137
153- if ( engine === 'native' ) {
154- it . todo ( 'super-dispatch: emits Lion.speak → Animal.speak (native gap #1326)' ) ;
155- } else {
156- it ( 'super-dispatch: emits Lion.speak → Animal.speak' , ( ) => {
157- const edge = callEdges . find (
158- ( e ) =>
159- e . caller_name === 'Lion.speak' &&
160- e . callee_name === 'Animal.speak' &&
161- e . callee_file === 'Animal.ts' ,
162- ) ;
163- expect (
164- edge ,
165- `Expected Lion.speak → Animal.speak edge (super-dispatch via class hierarchy).\nActual edges:\n${ JSON . stringify ( callEdges , null , 2 ) } ` ,
166- ) . toBeDefined ( ) ;
167- } ) ;
168- }
138+ it ( 'super-dispatch: emits Lion.speak → Animal.speak' , ( ) => {
139+ const edge = callEdges . find (
140+ ( e ) =>
141+ e . caller_name === 'Lion.speak' &&
142+ e . callee_name === 'Animal.speak' &&
143+ e . callee_file === 'Animal.ts' ,
144+ ) ;
145+ expect (
146+ edge ,
147+ `Expected Lion.speak → Animal.speak edge (super-dispatch via class hierarchy).\nActual edges:\n${ JSON . stringify ( callEdges , null , 2 ) } ` ,
148+ ) . toBeDefined ( ) ;
149+ } ) ;
169150
170151 // ── transitive multi-level CHA (issue #1311) ───────────────────────────
171152 // Hierarchy: IJob → AbstractJob (non-instantiated) → PrintJob / ScanJob
0 commit comments