File tree 1 file changed +4
-3
lines changed
packages/react-devtools-extensions/src/__tests__ 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -246,8 +246,7 @@ describe('parseHookNames', () => {
246
246
await test ( './__source__/__compiled__/external/ComponentWithCustomHook' ) ; // external source map
247
247
} ) ;
248
248
249
- // TODO (named hooks) The useContext() line number is slightly off
250
- xit ( 'should work for external hooks' , async ( ) => {
249
+ it ( 'should work for external hooks' , async ( ) => {
251
250
async function test ( path ) {
252
251
const Component = require ( path ) . Component ;
253
252
const hookNames = await getHookNamesForComponent ( Component ) ;
@@ -257,7 +256,9 @@ describe('parseHookNames', () => {
257
256
] ) ;
258
257
}
259
258
260
- await test ( './__source__/ComponentWithExternalCustomHooks' ) ; // original source (uncompiled)
259
+ // We can't test the uncompiled source here, because it either needs to get transformed,
260
+ // which would break the source mapping, or the import statements will fail.
261
+
261
262
await test (
262
263
'./__source__/__compiled__/inline/ComponentWithExternalCustomHooks' ,
263
264
) ; // inline source map
You can’t perform that action at this time.
0 commit comments