diff options
| author | David Sherret <dsherret@users.noreply.github.com> | 2023-10-26 21:27:50 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-10-26 21:27:50 -0400 |
| commit | 9ec18c35c7e6207fc96d6b2508c3bf37953c4f93 (patch) | |
| tree | 2e1ae90ab7f4bb79b3d119dd7bc8d5e4beec560b /cli/tests | |
| parent | 9026f20b2dc0ee97bde3cc6ea8438dafbec5fad3 (diff) | |
feat(doc): display non-exported types referenced in exported types (#20990)
Upgrades to deno_doc 0.70 which includes the feature for showing
non-exported types referenced in exported types as well as a much more
advanced deno doc that uses a symbol graph.
Diffstat (limited to 'cli/tests')
| -rw-r--r-- | cli/tests/integration/doc_tests.rs | 5 | ||||
| -rw-r--r-- | cli/tests/testdata/doc/referenced_private_types.out | 12 | ||||
| -rw-r--r-- | cli/tests/testdata/doc/referenced_private_types.ts | 7 |
3 files changed, 24 insertions, 0 deletions
diff --git a/cli/tests/integration/doc_tests.rs b/cli/tests/integration/doc_tests.rs index 72f5f4314..cdbee845b 100644 --- a/cli/tests/integration/doc_tests.rs +++ b/cli/tests/integration/doc_tests.rs @@ -47,6 +47,11 @@ itest!(deno_doc_types_header { http_server: true, }); +itest!(deno_doc_referenced_private_types { + args: "doc doc/referenced_private_types.ts", + output: "doc/referenced_private_types.out", +}); + itest!(_060_deno_doc_displays_all_overloads_in_details_view { args: "doc doc/060_deno_doc_displays_all_overloads_in_details_view.ts NS.test", diff --git a/cli/tests/testdata/doc/referenced_private_types.out b/cli/tests/testdata/doc/referenced_private_types.out new file mode 100644 index 000000000..507b91e3a --- /dev/null +++ b/cli/tests/testdata/doc/referenced_private_types.out @@ -0,0 +1,12 @@ +Defined in file:///[WILDCARD]/doc/referenced_private_types.ts:5:0 + +class MyClass + + prop: MyInterface + +Defined in file:///[WILDCARD]/doc/referenced_private_types.ts:1:0 + +private interface MyInterface + + prop?: string + diff --git a/cli/tests/testdata/doc/referenced_private_types.ts b/cli/tests/testdata/doc/referenced_private_types.ts new file mode 100644 index 000000000..9570d4625 --- /dev/null +++ b/cli/tests/testdata/doc/referenced_private_types.ts @@ -0,0 +1,7 @@ +interface MyInterface { + prop?: string; +} + +export class MyClass { + prop: MyInterface = {}; +} |
