diff --git a/tests/specs/namespace_reexport_member.txt b/tests/specs/namespace_reexport_member.txt new file mode 100644 index 00000000..f34af312 --- /dev/null +++ b/tests/specs/namespace_reexport_member.txt @@ -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" + } + } +]