File tree 5 files changed +13
-0
lines changed
tests/e2e/test-cases/names-collision-across-files
5 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ import { verboseLog } from './logger';
11
11
12
12
const renamingSupportedSymbols : readonly ts . SymbolFlags [ ] = [
13
13
ts . SymbolFlags . Alias ,
14
+ ts . SymbolFlags . FunctionScopedVariable ,
14
15
ts . SymbolFlags . BlockScopedVariable ,
15
16
ts . SymbolFlags . Class ,
16
17
ts . SymbolFlags . Enum ,
Original file line number Diff line number Diff line change @@ -2,6 +2,9 @@ const TEMPLATE = 'template1';
2
2
export default TEMPLATE ;
3
3
4
4
export const MergedSymbol = '' ;
5
+
6
+ export var Variable = 1 ;
7
+
5
8
export interface MergedSymbol {
6
9
test ( ) : void
7
10
} ;
Original file line number Diff line number Diff line change @@ -2,6 +2,9 @@ const TEMPLATE = 'template2';
2
2
export default TEMPLATE ;
3
3
4
4
export const MergedSymbol = '' ;
5
+
6
+ export var Variable = '' ;
7
+
5
8
export interface MergedSymbol {
6
9
test ( ) : void
7
10
} ;
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ export {
10
10
TypeName as T1 ,
11
11
func as f1 ,
12
12
NamespaceName as NS1 ,
13
+ Variable as V1 ,
13
14
14
15
// rename these to include them into import
15
16
AnotherInterface as AI1 ,
@@ -24,6 +25,7 @@ export {
24
25
TypeName as T2 ,
25
26
func as f2 ,
26
27
NamespaceName as NS2 ,
28
+ Variable as V2 ,
27
29
28
30
// yes, keep these without renaming so we can check that these aren't exported with wrong names
29
31
AnotherInterface ,
Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ declare namespace ExportEqNs$1 {
25
25
}
26
26
declare const TEMPLATE = "template1" ;
27
27
declare const MergedSymbol = "" ;
28
+ declare var Variable : number ;
28
29
interface MergedSymbol {
29
30
test ( ) : void ;
30
31
}
@@ -43,6 +44,7 @@ declare namespace NamespaceName {
43
44
}
44
45
declare const TEMPLATE$1 = "template2" ;
45
46
declare const MergedSymbol$1 = "" ;
47
+ declare var Variable$1 : string ;
46
48
interface MergedSymbol$1 {
47
49
test ( ) : void ;
48
50
}
@@ -93,6 +95,8 @@ export {
93
95
TEMPLATE$1 as TEMPLATE2 ,
94
96
TypeName as T1 ,
95
97
TypeName$1 as T2 ,
98
+ Variable as V1 ,
99
+ Variable$1 as V2 ,
96
100
anotherFunc as af1 ,
97
101
anotherFunc$1 as anotherFunc ,
98
102
func as f1 ,
You can’t perform that action at this time.
0 commit comments