Skip to content

Commit

Permalink
chore: failing test for re-exported namespace member
Browse files Browse the repository at this point in the history
  • Loading branch information
dsherret committed Nov 26, 2024
1 parent 6969d7b commit 3044c71
Showing 1 changed file with 215 additions and 0 deletions.
215 changes: 215 additions & 0 deletions tests/specs/namespace_reexport_member.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,215 @@
# mod.ts
import { Completions } from './resources.ts';

/** Doc */
export class MyApi {
/** Doc */
completions: Completions = {};
}

MyApi.Completions = Completions;

/** Doc */
export declare namespace MyApi {
export {
Completions as Completions,
};
}

export default MyApi;

# resources.ts
/** Doc */
export class Completions {}

# output.txt
Defined in file:///mod.ts:4:1

class MyApi
Doc

completions: Completions
Doc

Defined in file:///mod.ts:4:1

class default
Doc

completions: Completions
Doc

Defined in file:///mod.ts:12:1

namespace MyApi
Doc


Defined in file:///mod.ts:12:1

namespace default
Doc


Defined in file:///mod.ts:1:1



# output.json
[
{
"name": "MyApi",
"isDefault": false,
"location": {
"filename": "file:///mod.ts",
"line": 4,
"col": 0,
"byteIndex": 58
},
"declarationKind": "export",
"jsDoc": {
"doc": "Doc"
},
"kind": "class",
"classDef": {
"isAbstract": false,
"constructors": [],
"properties": [
{
"jsDoc": {
"doc": "Doc"
},
"tsType": {
"repr": "Completions",
"kind": "typeRef",
"typeRef": {
"typeParams": null,
"typeName": "Completions"
}
},
"readonly": false,
"accessibility": null,
"optional": false,
"isAbstract": false,
"isStatic": false,
"name": "completions",
"location": {
"filename": "file:///mod.ts",
"line": 6,
"col": 2,
"byteIndex": 95
}
}
],
"indexSignatures": [],
"methods": [],
"extends": null,
"implements": [],
"typeParams": [],
"superTypeParams": []
}
},
{
"name": "MyApi",
"isDefault": false,
"location": {
"filename": "file:///mod.ts",
"line": 12,
"col": 0,
"byteIndex": 175
},
"declarationKind": "export",
"jsDoc": {
"doc": "Doc"
},
"kind": "namespace",
"namespaceDef": {
"elements": []
}
},
{
"name": "default",
"isDefault": true,
"location": {
"filename": "file:///mod.ts",
"line": 4,
"col": 0,
"byteIndex": 58
},
"declarationKind": "export",
"jsDoc": {
"doc": "Doc"
},
"kind": "class",
"classDef": {
"isAbstract": false,
"constructors": [],
"properties": [
{
"jsDoc": {
"doc": "Doc"
},
"tsType": {
"repr": "Completions",
"kind": "typeRef",
"typeRef": {
"typeParams": null,
"typeName": "Completions"
}
},
"readonly": false,
"accessibility": null,
"optional": false,
"isAbstract": false,
"isStatic": false,
"name": "completions",
"location": {
"filename": "file:///mod.ts",
"line": 6,
"col": 2,
"byteIndex": 95
}
}
],
"indexSignatures": [],
"methods": [],
"extends": null,
"implements": [],
"typeParams": [],
"superTypeParams": []
}
},
{
"name": "default",
"isDefault": true,
"location": {
"filename": "file:///mod.ts",
"line": 12,
"col": 0,
"byteIndex": 175
},
"declarationKind": "export",
"jsDoc": {
"doc": "Doc"
},
"kind": "namespace",
"namespaceDef": {
"elements": []
}
},
{
"name": "Completions",
"location": {
"filename": "file:///mod.ts",
"line": 1,
"col": 0,
"byteIndex": 0
},
"declarationKind": "private",
"kind": "import",
"importDef": {
"src": "file:///resources.ts",
"imported": "Completions"
}
}
]

0 comments on commit 3044c71

Please sign in to comment.