2023-03-07 10:41:41 -06:00
|
|
|
// This test ensures that the `struct.B.html` only exists in `a`:
|
|
|
|
// since `a::B` is public (and inlined too), `self::a::B` doesn't
|
|
|
|
// need to be inlined as well.
|
|
|
|
|
|
|
|
#![crate_name = "foo"]
|
|
|
|
|
|
|
|
pub mod a {
|
2024-06-21 07:03:08 -05:00
|
|
|
//@ has 'foo/a/index.html'
|
2023-03-07 10:41:41 -06:00
|
|
|
// Should only contain "Structs".
|
2024-06-21 07:03:08 -05:00
|
|
|
//@ count - '//*[@id="main-content"]//*[@class="item-table"]' 1
|
|
|
|
//@ has - '//*[@id="structs"]' 'Structs'
|
|
|
|
//@ has - '//*[@id="main-content"]//a[@href="struct.A.html"]' 'A'
|
|
|
|
//@ has - '//*[@id="main-content"]//a[@href="struct.B.html"]' 'B'
|
2023-03-07 10:41:41 -06:00
|
|
|
mod b {
|
|
|
|
pub struct B;
|
|
|
|
}
|
|
|
|
pub use self::b::B;
|
|
|
|
pub struct A;
|
|
|
|
}
|
|
|
|
|
2024-06-21 07:03:08 -05:00
|
|
|
//@ has 'foo/index.html'
|
|
|
|
//@ !has - '//*[@id="structs"]' 'Structs'
|
|
|
|
//@ has - '//*[@id="reexports"]' 'Re-exports'
|
|
|
|
//@ has - '//*[@id="modules"]' 'Modules'
|
|
|
|
//@ has - '//*[@id="main-content"]//*[@id="reexport.A"]' 'pub use self::a::A;'
|
|
|
|
//@ has - '//*[@id="main-content"]//*[@id="reexport.B"]' 'pub use self::a::B;'
|
2023-03-07 10:41:41 -06:00
|
|
|
// Should only contain "Modules" and "Re-exports".
|
2024-06-21 07:03:08 -05:00
|
|
|
//@ count - '//*[@id="main-content"]//*[@class="item-table"]' 2
|
2023-03-07 10:41:41 -06:00
|
|
|
pub use self::a::{A, B};
|