More tests/rustdoc-html cleanups

This commit is contained in:
Guillaume Gomez
2026-10-10 17:56:26 +02:00
parent 34f4a807e2
commit 50d38d3d8d
23 changed files with 6 additions and 2 deletions

View File

@@ -144,6 +144,10 @@ page, etc.
Contains tests checking the content of the source code pages (when you click on the `source`
links).
## `tests/rustdoc-html/struct`
Same as `tests/rustdoc-html/enum` but for struct items.
## `tests/rustdoc-html/synthetic_auto`
Somewhat equivalent to the `auto` folder's tests. Both should likely be merged.

View File

@@ -1,13 +1,13 @@
#![crate_name = "foo"]
//@ has foo/struct.Bar.html
//@ !has - '//*[@id="impl-Sized"]' ''
//@ !has - '//h3[@class="code-header"]' 'impl Sized for Bar'
pub struct Bar {
a: u16,
}
//@ has foo/struct.Foo.html
//@ !has - '//*[@id="impl-Sized"]' ''
//@ !has - '//h3[@class="code-header"]' 'impl Sized for Foo'
pub struct Foo<T: ?Sized>(T);
//@ has foo/struct.Unsized.html