From 4547b622d8d29df964fa2914213088b148c498fc Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:18:32 +0200 Subject: Merging upstream version 1.67.1+dfsg1. Signed-off-by: Daniel Baumann --- src/test/rustdoc-js/reexport.js | 17 +++++++++++++++++ src/test/rustdoc-js/reexport.rs | 11 +++++++++++ 2 files changed, 28 insertions(+) create mode 100644 src/test/rustdoc-js/reexport.js create mode 100644 src/test/rustdoc-js/reexport.rs (limited to 'src/test/rustdoc-js') diff --git a/src/test/rustdoc-js/reexport.js b/src/test/rustdoc-js/reexport.js new file mode 100644 index 000000000..871e75d9b --- /dev/null +++ b/src/test/rustdoc-js/reexport.js @@ -0,0 +1,17 @@ +// exact-check + +const QUERY = ['Subscriber', 'AnotherOne']; + +const EXPECTED = [ + { + 'others': [ + { 'path': 'reexport::fmt', 'name': 'Subscriber' }, + { 'path': 'reexport', 'name': 'FmtSubscriber' }, + ], + }, + { + 'others': [ + { 'path': 'reexport', 'name': 'AnotherOne' }, + ], + }, +]; diff --git a/src/test/rustdoc-js/reexport.rs b/src/test/rustdoc-js/reexport.rs new file mode 100644 index 000000000..d69b2901e --- /dev/null +++ b/src/test/rustdoc-js/reexport.rs @@ -0,0 +1,11 @@ +// This test enforces that the (renamed) reexports are present in the search results. + +pub mod fmt { + pub struct Subscriber; +} +mod foo { + pub struct AnotherOne; +} + +pub use foo::AnotherOne; +pub use fmt::Subscriber as FmtSubscriber; -- cgit v1.2.3