mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-29 10:13:54 +00:00
Rollup merge of #103758 - GuillaumeGomez:reexports-search-result-test, r=notriddle
Add regression test for reexports in search results Fixes https://github.com/rust-lang/rust/issues/86337. r? ``@notriddle``
This commit is contained in:
commit
4473fcd6f2
17
src/test/rustdoc-js/reexport.js
Normal file
17
src/test/rustdoc-js/reexport.js
Normal file
@ -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' },
|
||||
],
|
||||
},
|
||||
];
|
11
src/test/rustdoc-js/reexport.rs
Normal file
11
src/test/rustdoc-js/reexport.rs
Normal file
@ -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;
|
Loading…
Reference in New Issue
Block a user