File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -482,6 +482,68 @@ import {x,y} from './foo'
482482 errors : [ "'../constants' imported multiple times." , "'../constants' imported multiple times." ] ,
483483 ...jsxConfig ,
484484 } ) ,
485+
486+ test ( {
487+ code : `
488+ import {A1,} from 'foo';
489+ import {B1,} from 'foo';
490+ import {C1,} from 'foo';
491+
492+ import {
493+ A2,
494+ } from 'bar';
495+ import {
496+ B2,
497+ } from 'bar';
498+ import {
499+ C2,
500+ } from 'bar';
501+
502+ ` ,
503+ output : `
504+ import {A1,B1,C1} from 'foo';
505+ ${ '' }
506+ import {
507+ A2,
508+ ${ '' }
509+ B2,
510+ C2} from 'bar';
511+ ${ '' }
512+ ` ,
513+ errors : [
514+ {
515+ message : "'foo' imported multiple times." ,
516+ line : 2 ,
517+ column : 27 ,
518+ } ,
519+ {
520+ message : "'foo' imported multiple times." ,
521+ line : 3 ,
522+ column : 27 ,
523+ } ,
524+ {
525+ message : "'foo' imported multiple times." ,
526+ line : 4 ,
527+ column : 27 ,
528+ } ,
529+ {
530+ message : "'bar' imported multiple times." ,
531+ line : 8 ,
532+ column : 16 ,
533+ } ,
534+ {
535+ message : "'bar' imported multiple times." ,
536+ line : 11 ,
537+ column : 16 ,
538+ } ,
539+ {
540+ message : "'bar' imported multiple times." ,
541+ line : 14 ,
542+ column : 16 ,
543+ } ,
544+ ] ,
545+ ...jsxConfig ,
546+ } ) ,
485547 ] ,
486548} ) ;
487549
You can’t perform that action at this time.
0 commit comments