Skip to content

Commit 54ed3c4

Browse files
committed
Add a unit test
1 parent 3d224bd commit 54ed3c4

File tree

4 files changed

+63
-0
lines changed

4 files changed

+63
-0
lines changed
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
//// [namespacesDeclaration.ts]
2+
3+
module M {
4+
export namespace N {
5+
export module M2 {
6+
export interface I {}
7+
}
8+
}
9+
}
10+
11+
//// [namespacesDeclaration.js]
12+
13+
14+
//// [namespacesDeclaration.d.ts]
15+
declare module M {
16+
namespace N {
17+
module M2 {
18+
interface I {
19+
}
20+
}
21+
}
22+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
=== tests/cases/compiler/namespacesDeclaration.ts ===
2+
3+
module M {
4+
>M : Symbol(M, Decl(namespacesDeclaration.ts, 0, 0))
5+
6+
export namespace N {
7+
>N : Symbol(N, Decl(namespacesDeclaration.ts, 1, 10))
8+
9+
export module M2 {
10+
>M2 : Symbol(M2, Decl(namespacesDeclaration.ts, 2, 23))
11+
12+
export interface I {}
13+
>I : Symbol(I, Decl(namespacesDeclaration.ts, 3, 24))
14+
}
15+
}
16+
}
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
=== tests/cases/compiler/namespacesDeclaration.ts ===
2+
3+
module M {
4+
>M : any
5+
6+
export namespace N {
7+
>N : any
8+
9+
export module M2 {
10+
>M2 : any
11+
12+
export interface I {}
13+
>I : I
14+
}
15+
}
16+
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
// @declaration: true
2+
3+
module M {
4+
export namespace N {
5+
export module M2 {
6+
export interface I {}
7+
}
8+
}
9+
}

0 commit comments

Comments
 (0)