about summary refs log tree commit diff
path: root/tests/rustdoc
diff options
context:
space:
mode:
Diffstat (limited to 'tests/rustdoc')
-rw-r--r--tests/rustdoc/anonymous-reexport-108931.rs4
-rw-r--r--tests/rustdoc/anonymous-reexport.rs2
-rw-r--r--tests/rustdoc/attributes-inlining-108281.rs6
-rw-r--r--tests/rustdoc/cfg_doc_reexport.rs4
-rw-r--r--tests/rustdoc/deprecated.rs7
-rw-r--r--tests/rustdoc/display-hidden-items.rs16
-rw-r--r--tests/rustdoc/doc-cfg.rs6
-rw-r--r--tests/rustdoc/doc-hidden-reexports-109449.rs6
-rw-r--r--tests/rustdoc/double-hyphen-to-dash.rs2
-rw-r--r--tests/rustdoc/duplicate-cfg.rs4
-rw-r--r--tests/rustdoc/footnote-in-summary.rs4
-rw-r--r--tests/rustdoc/glob-reexport-attribute-merge-120487.rs4
-rw-r--r--tests/rustdoc/glob-reexport-attribute-merge-doc-auto-cfg.rs4
-rw-r--r--tests/rustdoc/glob-shadowing-const.rs4
-rw-r--r--tests/rustdoc/glob-shadowing.rs18
-rw-r--r--tests/rustdoc/impl-on-ty-alias-issue-119015.rs4
-rw-r--r--tests/rustdoc/inline-private-with-intermediate-doc-hidden.rs2
-rw-r--r--tests/rustdoc/inline_cross/inline_hidden.rs8
-rw-r--r--tests/rustdoc/inline_cross/macros.rs6
-rw-r--r--tests/rustdoc/internal.rs2
-rw-r--r--tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs8
-rw-r--r--tests/rustdoc/item-desc-list-at-start.item-table.html2
-rw-r--r--tests/rustdoc/item-desc-list-at-start.rs7
-rw-r--r--tests/rustdoc/macro-rules-broken-intra-doc-106142.rs17
-rw-r--r--tests/rustdoc/nested-items-issue-111415.rs2
-rw-r--r--tests/rustdoc/overlapping-reexport-105735-2.rs4
-rw-r--r--tests/rustdoc/overlapping-reexport-105735.rs4
-rw-r--r--tests/rustdoc/pub-use-root-path-95873.rs2
-rw-r--r--tests/rustdoc/reexport-cfg.rs8
-rw-r--r--tests/rustdoc/reexport-check.rs4
-rw-r--r--tests/rustdoc/reexport-doc-hidden-inside-private.rs2
-rw-r--r--tests/rustdoc/reexport-of-reexport-108679.rs3
-rw-r--r--tests/rustdoc/reexport-trait-from-hidden-111064.rs2
-rw-r--r--tests/rustdoc/short-docblock.rs11
-rw-r--r--tests/rustdoc/stability.rs6
-rw-r--r--tests/rustdoc/staged-api-deprecated-unstable-32374.rs8
-rw-r--r--tests/rustdoc/summary-header-46377.rs2
37 files changed, 92 insertions, 113 deletions
diff --git a/tests/rustdoc/anonymous-reexport-108931.rs b/tests/rustdoc/anonymous-reexport-108931.rs
index f4cc7f12396..b995c89b614 100644
--- a/tests/rustdoc/anonymous-reexport-108931.rs
+++ b/tests/rustdoc/anonymous-reexport-108931.rs
@@ -16,7 +16,7 @@ mod bar {
 //@ count - '//*[@id="main-content"]/h2' 2
 //@ has - '//*[@id="main-content"]/h2' 'Re-exports'
 //@ has - '//*[@id="main-content"]/h2' 'Modules'
-//@ has - '//*[@id="main-content"]//*[@class="item-table"]//li//code' 'pub use foo::Foo as _;'
-//@ has - '//*[@id="main-content"]//*[@class="item-table"]//li//code' 'pub use bar::Bar as _;'
+//@ has - '//*[@id="main-content"]//*[@class="item-table reexports"]/dt//code' 'pub use foo::Foo as _;'
+//@ has - '//*[@id="main-content"]//*[@class="item-table reexports"]/dt//code' 'pub use bar::Bar as _;'
 pub use foo::Foo as _;
 pub use bar::Bar as _;
diff --git a/tests/rustdoc/anonymous-reexport.rs b/tests/rustdoc/anonymous-reexport.rs
index 8021008dc66..bf5fa93f953 100644
--- a/tests/rustdoc/anonymous-reexport.rs
+++ b/tests/rustdoc/anonymous-reexport.rs
@@ -9,7 +9,7 @@
 //@ has - '//*[@id="main-content"]/h2' 'Structs'
 //@ has - '//*[@id="main-content"]/h2' 'Re-exports'
 // The 3 re-exports.
-//@ count - '//*[@id="main-content"]//*[@class="item-table"]//li//code' 3
+//@ count - '//*[@id="main-content"]//*[@class="item-table reexports"]/dt//code' 3
 // The public struct.
 //@ count - '//*[@id="main-content"]//a[@class="struct"]' 1
 
diff --git a/tests/rustdoc/attributes-inlining-108281.rs b/tests/rustdoc/attributes-inlining-108281.rs
index ba6c570b59b..9dfaf1a6846 100644
--- a/tests/rustdoc/attributes-inlining-108281.rs
+++ b/tests/rustdoc/attributes-inlining-108281.rs
@@ -11,15 +11,15 @@ mod sub {
     pub fn public() {}
 }
 
-//@ matches - '//*[@class="desc docblock-short"]' '^Displayed$'
+//@ matches - '//dd' '^Displayed$'
 /// Displayed
 #[doc(inline)]
 pub use crate::bar as Bar;
-//@ matches - '//*[@class="desc docblock-short"]' '^Hello\sDisplayed$'
+//@ matches - '//dd' '^Hello\sDisplayed$'
 #[doc(inline)]
 /// Hello
 pub use crate::Bar as Bar2;
 
-//@ matches - '//*[@class="desc docblock-short"]' '^Public$'
+//@ matches - '//dd' '^Public$'
 /// Public
 pub use crate::sub::public as Public;
diff --git a/tests/rustdoc/cfg_doc_reexport.rs b/tests/rustdoc/cfg_doc_reexport.rs
index a07e4fe2f02..f8101e2a958 100644
--- a/tests/rustdoc/cfg_doc_reexport.rs
+++ b/tests/rustdoc/cfg_doc_reexport.rs
@@ -5,8 +5,8 @@
 #![no_core]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="item-name"]/*[@class="stab portability"]' 'foobar'
-//@ has - '//*[@class="item-name"]/*[@class="stab portability"]' 'bar'
+//@ has - '//dt/*[@class="stab portability"]' 'foobar'
+//@ has - '//dt/*[@class="stab portability"]' 'bar'
 
 #[doc(cfg(feature = "foobar"))]
 mod imp_priv {
diff --git a/tests/rustdoc/deprecated.rs b/tests/rustdoc/deprecated.rs
index b39da9b440a..a84657a3df5 100644
--- a/tests/rustdoc/deprecated.rs
+++ b/tests/rustdoc/deprecated.rs
@@ -1,6 +1,5 @@
-//@ has deprecated/index.html '//*[@class="item-name"]/span[@class="stab deprecated"]' \
-//      'Deprecated'
-//@ has - '//*[@class="desc docblock-short"]' 'Deprecated docs'
+//@ has deprecated/index.html '//dt/span[@class="stab deprecated"]' 'Deprecated'
+//@ has - '//dd' 'Deprecated docs'
 
 //@ has deprecated/struct.S.html '//*[@class="stab deprecated"]' \
 //      'Deprecated since 1.0.0: text'
@@ -8,7 +7,7 @@
 #[deprecated(since = "1.0.0", note = "text")]
 pub struct S;
 
-//@ matches deprecated/index.html '//*[@class="desc docblock-short"]' '^Docs'
+//@ matches deprecated/index.html '//dd' '^Docs'
 /// Docs
 pub struct T;
 
diff --git a/tests/rustdoc/display-hidden-items.rs b/tests/rustdoc/display-hidden-items.rs
index d9f53435e46..40cd636e2fe 100644
--- a/tests/rustdoc/display-hidden-items.rs
+++ b/tests/rustdoc/display-hidden-items.rs
@@ -5,19 +5,19 @@
 #![crate_name = "foo"]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="item-name"]/span[@title="Hidden item"]' '๐Ÿ‘ป'
+//@ has - '//dt/span[@title="Hidden item"]' '๐Ÿ‘ป'
 
 //@ has - '//*[@id="reexport.hidden_reexport"]/code' '#[doc(hidden)] pub use hidden::inside_hidden as hidden_reexport;'
 #[doc(hidden)]
 pub use hidden::inside_hidden as hidden_reexport;
 
-//@ has - '//*[@class="item-name"]/a[@class="trait"]' 'TraitHidden'
+//@ has - '//dt/a[@class="trait"]' 'TraitHidden'
 //@ has 'foo/trait.TraitHidden.html'
 //@ has - '//code' '#[doc(hidden)] pub trait TraitHidden'
 #[doc(hidden)]
 pub trait TraitHidden {}
 
-//@ has 'foo/index.html' '//*[@class="item-name"]/a[@class="trait"]' 'Trait'
+//@ has 'foo/index.html' '//dt/a[@class="trait"]' 'Trait'
 pub trait Trait {
     //@ has 'foo/trait.Trait.html'
     //@ has - '//*[@id="associatedconstant.BAR"]/*[@class="code-header"]' '#[doc(hidden)] const BAR: u32 = 0u32'
@@ -29,7 +29,7 @@ pub trait Trait {
     fn foo() {}
 }
 
-//@ has 'foo/index.html' '//*[@class="item-name"]/a[@class="struct"]' 'Struct'
+//@ has 'foo/index.html' '//dt/a[@class="struct"]' 'Struct'
 //@ has 'foo/struct.Struct.html'
 pub struct Struct {
     //@ has - '//*[@id="structfield.a"]/code' 'a: u32'
@@ -50,7 +50,7 @@ impl Trait for Struct {
 //@ has - '//*[@id="impl-TraitHidden-for-Struct"]/*[@class="code-header"]' 'impl TraitHidden for Struct'
 impl TraitHidden for Struct {}
 
-//@ has 'foo/index.html' '//*[@class="item-name"]/a[@class="enum"]' 'HiddenEnum'
+//@ has 'foo/index.html' '//dt/a[@class="enum"]' 'HiddenEnum'
 //@ has 'foo/enum.HiddenEnum.html'
 //@ has - '//code' '#[doc(hidden)] pub enum HiddenEnum'
 #[doc(hidden)]
@@ -58,18 +58,18 @@ pub enum HiddenEnum {
     A,
 }
 
-//@ has 'foo/index.html' '//*[@class="item-name"]/a[@class="enum"]' 'Enum'
+//@ has 'foo/index.html' '//dt/a[@class="enum"]' 'Enum'
 pub enum Enum {
     //@ has 'foo/enum.Enum.html' '//*[@id="variant.A"]/*[@class="code-header"]' 'A'
     #[doc(hidden)]
     A,
 }
 
-//@ has 'foo/index.html' '//*[@class="item-name"]/a[@class="mod"]' 'hidden'
+//@ has 'foo/index.html' '//dt/a[@class="mod"]' 'hidden'
 #[doc(hidden)]
 pub mod hidden {
     //@ has 'foo/hidden/index.html'
-    //@ has - '//*[@class="item-name"]/a[@class="fn"]' 'inside_hidden'
+    //@ has - '//dt/a[@class="fn"]' 'inside_hidden'
     //@ has 'foo/hidden/fn.inside_hidden.html'
     pub fn inside_hidden() {}
 }
diff --git a/tests/rustdoc/doc-cfg.rs b/tests/rustdoc/doc-cfg.rs
index 6c973b5666b..652c8419b4f 100644
--- a/tests/rustdoc/doc-cfg.rs
+++ b/tests/rustdoc/doc-cfg.rs
@@ -12,7 +12,7 @@ pub struct Portable;
 //@ has doc_cfg/unix_only/index.html \
 //  '//*[@id="main-content"]/*[@class="item-info"]/*[@class="stab portability"]' \
 //  'Available on Unix only.'
-//@ matches - '//*[@class="item-name"]//*[@class="stab portability"]' '\AARM\Z'
+//@ matches - '//dt//*[@class="stab portability"]' '\AARM\Z'
 //@ count - '//*[@class="stab portability"]' 2
 #[doc(cfg(unix))]
 pub mod unix_only {
@@ -42,7 +42,7 @@ pub mod unix_only {
 //@ has doc_cfg/wasi_only/index.html \
 //  '//*[@id="main-content"]/*[@class="item-info"]/*[@class="stab portability"]' \
 //  'Available on WASI only.'
-//@ matches - '//*[@class="item-name"]//*[@class="stab portability"]' '\AWebAssembly\Z'
+//@ matches - '//dt//*[@class="stab portability"]' '\AWebAssembly\Z'
 //@ count - '//*[@class="stab portability"]' 2
 #[doc(cfg(target_os = "wasi"))]
 pub mod wasi_only {
@@ -74,7 +74,7 @@ pub mod wasi_only {
 
 // the portability header is different on the module view versus the full view
 //@ has doc_cfg/index.html
-//@ matches - '//*[@class="item-name"]//*[@class="stab portability"]' '\Aavx\Z'
+//@ matches - '//dt//*[@class="stab portability"]' '\Aavx\Z'
 
 //@ has doc_cfg/fn.uses_target_feature.html
 //@ has - '//*[@id="main-content"]/*[@class="item-info"]/*[@class="stab portability"]' \
diff --git a/tests/rustdoc/doc-hidden-reexports-109449.rs b/tests/rustdoc/doc-hidden-reexports-109449.rs
index cc3679f6196..8f195544120 100644
--- a/tests/rustdoc/doc-hidden-reexports-109449.rs
+++ b/tests/rustdoc/doc-hidden-reexports-109449.rs
@@ -26,7 +26,7 @@ pub mod single_reexport {
     //@ has 'foo/single_reexport/index.html'
 
     // First we check that we have 4 type aliases.
-    //@ count - '//*[@id="main-content"]/*[@class="item-table"]//code' 4
+    //@ count - '//*[@id="main-content"]/*[@class="item-table reexports"]//code' 4
 
     // Then we check that we have the correct link for each re-export.
 
@@ -131,10 +131,10 @@ mod private {
 pub mod doc_hidden_reexport {
     //@ has 'foo/doc_hidden_reexport/index.html'
     // Ensure there is only one item in this page and that it's a struct.
-    //@ count - '//*[@class="item-name"]' 1
+    //@ count - '//dt' 1
     //@ has - '//a[@class="struct"]' 'Reexport'
     // Check that the `#[doc(hidden)]` re-export's attributes are not taken into account.
-    //@ has - '//*[@class="desc docblock-short"]' 'Visible. Original.'
+    //@ has - '//dd' 'Visible. Original.'
     /// Visible.
     pub use self::Bar3 as Reexport;
     /// Hidden.
diff --git a/tests/rustdoc/double-hyphen-to-dash.rs b/tests/rustdoc/double-hyphen-to-dash.rs
index 009de4faf41..c14acd065cd 100644
--- a/tests/rustdoc/double-hyphen-to-dash.rs
+++ b/tests/rustdoc/double-hyphen-to-dash.rs
@@ -2,7 +2,7 @@
 
 #![crate_name = "foo"]
 
-//@ has 'foo/index.html' '//*[@class="desc docblock-short"]' 'โ€“'
+//@ has 'foo/index.html' '//dd' 'โ€“'
 //@ has 'foo/struct.Bar.html' '//*[@class="docblock"]' 'โ€“'
 
 /// --
diff --git a/tests/rustdoc/duplicate-cfg.rs b/tests/rustdoc/duplicate-cfg.rs
index 87c089e9735..93f26ab944d 100644
--- a/tests/rustdoc/duplicate-cfg.rs
+++ b/tests/rustdoc/duplicate-cfg.rs
@@ -2,8 +2,8 @@
 #![feature(doc_cfg)]
 
 //@ has 'foo/index.html'
-//@ matches '-' '//*[@class="item-name"]//*[@class="stab portability"]' '^sync$'
-//@ has '-' '//*[@class="item-name"]//*[@class="stab portability"]/@title' 'Available on crate feature `sync` only'
+//@ matches '-' '//dt//*[@class="stab portability"]' '^sync$'
+//@ has '-' '//dt//*[@class="stab portability"]/@title' 'Available on crate feature `sync` only'
 
 //@ has 'foo/struct.Foo.html'
 //@ has '-' '//*[@class="stab portability"]' 'sync'
diff --git a/tests/rustdoc/footnote-in-summary.rs b/tests/rustdoc/footnote-in-summary.rs
index d69282f1041..2a9668a9963 100644
--- a/tests/rustdoc/footnote-in-summary.rs
+++ b/tests/rustdoc/footnote-in-summary.rs
@@ -4,8 +4,8 @@
 #![crate_name = "foo"]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="desc docblock-short"]' 'hello bla'
-//@ !has - '//*[@class="desc docblock-short"]/sup' '1'
+//@ has - '//dd' 'hello bla'
+//@ !has - '//dd/sup' '1'
 
 //@ has 'foo/struct.S.html'
 //@ has - '//*[@class="docblock"]//sup' '1'
diff --git a/tests/rustdoc/glob-reexport-attribute-merge-120487.rs b/tests/rustdoc/glob-reexport-attribute-merge-120487.rs
index 2fa10f546d5..5b918e0ffd9 100644
--- a/tests/rustdoc/glob-reexport-attribute-merge-120487.rs
+++ b/tests/rustdoc/glob-reexport-attribute-merge-120487.rs
@@ -7,9 +7,9 @@
 
 //@ has 'foo/index.html'
 // There are two items.
-//@ count - '//*[@class="item-table"]//div[@class="item-name"]' 2
+//@ count - '//*[@class="item-table"]/dt' 2
 // Only one of them should have an attribute.
-//@ count - '//*[@class="item-table"]//div[@class="item-name"]/*[@class="stab portability"]' 1
+//@ count - '//*[@class="item-table"]/dt/*[@class="stab portability"]' 1
 
 mod a {
     #[doc(cfg(not(feature = "a")))]
diff --git a/tests/rustdoc/glob-reexport-attribute-merge-doc-auto-cfg.rs b/tests/rustdoc/glob-reexport-attribute-merge-doc-auto-cfg.rs
index 314b457c2ad..d0a2165ec8a 100644
--- a/tests/rustdoc/glob-reexport-attribute-merge-doc-auto-cfg.rs
+++ b/tests/rustdoc/glob-reexport-attribute-merge-doc-auto-cfg.rs
@@ -6,9 +6,9 @@
 
 //@ has 'foo/index.html'
 // There are two items.
-//@ count - '//*[@class="item-table"]//div[@class="item-name"]' 2
+//@ count - '//*[@class="item-table"]/dt' 2
 // Only one of them should have an attribute.
-//@ count - '//*[@class="item-table"]//div[@class="item-name"]/*[@class="stab portability"]' 1
+//@ count - '//*[@class="item-table"]/dt/*[@class="stab portability"]' 1
 
 mod a {
     #[cfg(not(feature = "a"))]
diff --git a/tests/rustdoc/glob-shadowing-const.rs b/tests/rustdoc/glob-shadowing-const.rs
index 1eb5596cd9c..fbc22dbccaa 100644
--- a/tests/rustdoc/glob-shadowing-const.rs
+++ b/tests/rustdoc/glob-shadowing-const.rs
@@ -15,6 +15,6 @@ mod sub4 {
 pub use sub4::inner::*;
 
 //@ has 'foo/index.html'
-//@ has - '//div[@class="desc docblock-short"]' '1'
-//@ !has - '//div[@class="desc docblock-short"]' '0'
+//@ has - '//dd' '1'
+//@ !has - '//dd' '0'
 fn main() { assert_eq!(X, 1); }
diff --git a/tests/rustdoc/glob-shadowing.rs b/tests/rustdoc/glob-shadowing.rs
index a051bd407d5..d9e9ead3f9a 100644
--- a/tests/rustdoc/glob-shadowing.rs
+++ b/tests/rustdoc/glob-shadowing.rs
@@ -1,17 +1,17 @@
 //@ has 'glob_shadowing/index.html'
-//@ count - '//div[@class="item-name"]' 6
-//@ !has - '//div[@class="desc docblock-short"]' 'sub1::describe'
-//@ has - '//div[@class="desc docblock-short"]' 'sub2::describe'
+//@ count - '//dt' 6
+//@ !has - '//dd' 'sub1::describe'
+//@ has - '//dd' 'sub2::describe'
 
-//@ !has - '//div[@class="desc docblock-short"]' 'sub1::describe2'
+//@ !has - '//dd' 'sub1::describe2'
 
-//@ !has - '//div[@class="desc docblock-short"]' 'sub1::prelude'
-//@ has - '//div[@class="desc docblock-short"]' 'mod::prelude'
+//@ !has - '//dd' 'sub1::prelude'
+//@ has - '//dd' 'mod::prelude'
 
-//@ has - '//div[@class="desc docblock-short"]' 'sub1::Foo (struct)'
-//@ has - '//div[@class="desc docblock-short"]' 'mod::Foo (function)'
+//@ has - '//dd' 'sub1::Foo (struct)'
+//@ has - '//dd' 'mod::Foo (function)'
 
-//@ has - '//div[@class="desc docblock-short"]' 'sub4::inner::X'
+//@ has - '//dd' 'sub4::inner::X'
 
 //@ has 'glob_shadowing/fn.describe.html'
 //@ has - '//div[@class="docblock"]' 'sub2::describe'
diff --git a/tests/rustdoc/impl-on-ty-alias-issue-119015.rs b/tests/rustdoc/impl-on-ty-alias-issue-119015.rs
index cea0f5565a2..a514bc35bfc 100644
--- a/tests/rustdoc/impl-on-ty-alias-issue-119015.rs
+++ b/tests/rustdoc/impl-on-ty-alias-issue-119015.rs
@@ -2,8 +2,8 @@
 
 //@ has 'foo/index.html'
 // There should be only `type A`.
-//@ count - '//*[@class="item-table"]//*[@class="item-name"]' 1
-//@ has - '//*[@class="item-name"]/a[@href="type.A.html"]' 'A'
+//@ count - '//*[@class="item-table"]//dt' 1
+//@ has - '//dt/a[@href="type.A.html"]' 'A'
 
 mod foo {
     pub struct S;
diff --git a/tests/rustdoc/inline-private-with-intermediate-doc-hidden.rs b/tests/rustdoc/inline-private-with-intermediate-doc-hidden.rs
index 752f3843eea..d27ecbad169 100644
--- a/tests/rustdoc/inline-private-with-intermediate-doc-hidden.rs
+++ b/tests/rustdoc/inline-private-with-intermediate-doc-hidden.rs
@@ -9,7 +9,7 @@
 //@ count - '//*[@id="main-content"]/*[@class="section-header"]' 1
 //@ has - '//*[@id="main-content"]/*[@class="section-header"]' 'Structs'
 //@ has - '//*[@id="main-content"]//a[@href="struct.Reexport.html"]' 'Reexport'
-//@ has - '//*[@id="main-content"]//*[@class="desc docblock-short"]' 'Visible. Original.'
+//@ has - '//*[@id="main-content"]//dd' 'Visible. Original.'
 
 mod private {
     /// Original.
diff --git a/tests/rustdoc/inline_cross/inline_hidden.rs b/tests/rustdoc/inline_cross/inline_hidden.rs
index 095cd2d3c55..49ca2db6a22 100644
--- a/tests/rustdoc/inline_cross/inline_hidden.rs
+++ b/tests/rustdoc/inline_cross/inline_hidden.rs
@@ -11,14 +11,14 @@ extern crate rustdoc_hidden;
 pub use rustdoc_hidden::Foo;
 
 // Even if the foreign item has `doc(hidden)`, we should be able to inline it.
-//@ has - '//*[@class="item-name"]/a[@class="struct"]' 'Inlined'
+//@ has - '//dt/a[@class="struct"]' 'Inlined'
 #[doc(inline)]
 pub use rustdoc_hidden::Foo as Inlined;
 
 // Even with this import, we should not see `Foo`.
-//@ count - '//*[@class="item-name"]' 4
-//@ has - '//*[@class="item-name"]/a[@class="struct"]' 'Bar'
-//@ has - '//*[@class="item-name"]/a[@class="fn"]' 'foo'
+//@ count - '//dt' 4
+//@ has - '//dt/a[@class="struct"]' 'Bar'
+//@ has - '//dt/a[@class="fn"]' 'foo'
 pub use rustdoc_hidden::*;
 
 //@ has inline_hidden/fn.foo.html
diff --git a/tests/rustdoc/inline_cross/macros.rs b/tests/rustdoc/inline_cross/macros.rs
index aab7a3650b1..57eec77899e 100644
--- a/tests/rustdoc/inline_cross/macros.rs
+++ b/tests/rustdoc/inline_cross/macros.rs
@@ -6,10 +6,8 @@
 
 extern crate macros;
 
-//@ has foo/index.html '//*[@class="item-name"]/span[@class="stab deprecated"]' \
-//         Deprecated
-//@ has - '//*[@class="item-name"]/span[@class="stab unstable"]' \
-//         Experimental
+//@ has foo/index.html '//dt/span[@class="stab deprecated"]' Deprecated
+//@ has - '//dt/span[@class="stab unstable"]' Experimental
 
 //@ has foo/macro.my_macro.html
 //@ has - '//*[@class="docblock"]' 'docs for my_macro'
diff --git a/tests/rustdoc/internal.rs b/tests/rustdoc/internal.rs
index e0bccefda1d..244e9138f2b 100644
--- a/tests/rustdoc/internal.rs
+++ b/tests/rustdoc/internal.rs
@@ -8,7 +8,7 @@
 //@ !matches internal/index.html \
 //      '//*[@class="desc docblock-short"]/span[@class="stab internal"]' \
 //      ''
-//@ matches - '//*[@class="desc docblock-short"]' 'Docs'
+//@ matches - '//dd' 'Docs'
 
 //@ !has internal/struct.S.html '//*[@class="stab unstable"]' ''
 //@ !has internal/struct.S.html '//*[@class="stab internal"]' ''
diff --git a/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs b/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs
index 06cb764423e..f0362f684ad 100644
--- a/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs
+++ b/tests/rustdoc/intra-doc/module-scope-name-resolution-55364.rs
@@ -32,8 +32,8 @@ pub mod subone {
 //@ has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.foo.html"]' 'foo'
 //@ has - '//section[@id="main-content"]/details/div[@class="docblock"]//a[@href="../fn.bar.html"]' 'bar'
 // Though there should be such links later
-//@ has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="item-name"]/a[@class="fn"][@href="fn.foo.html"]' 'foo'
-//@ has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="item-name"]/a[@class="fn"][@href="fn.bar.html"]' 'bar'
+//@ has - '//section[@id="main-content"]/dl[@class="item-table"]/dt/a[@class="fn"][@href="fn.foo.html"]' 'foo'
+//@ has - '//section[@id="main-content"]/dl[@class="item-table"]/dt/a[@class="fn"][@href="fn.bar.html"]' 'bar'
 /// See either [foo] or [bar].
 pub mod subtwo {
 
@@ -71,8 +71,8 @@ pub mod subthree {
 // Next we go *deeper* - In order to ensure it's not just "this or parent"
 // we test `crate::` and a `super::super::...` chain
 //@ has foo/subfour/subfive/subsix/subseven/subeight/index.html
-//@ has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subone/fn.foo.html"]' 'other foo'
-//@ has - '//section[@id="main-content"]/ul[@class="item-table"]//div[@class="desc docblock-short"]//a[@href="../../../../../subtwo/fn.bar.html"]' 'other bar'
+//@ has - '//section[@id="main-content"]/dl[@class="item-table"]/dd//a[@href="../../../../../subone/fn.foo.html"]' 'other foo'
+//@ has - '//section[@id="main-content"]/dl[@class="item-table"]/dd//a[@href="../../../../../subtwo/fn.bar.html"]' 'other bar'
 pub mod subfour {
     pub mod subfive {
         pub mod subsix {
diff --git a/tests/rustdoc/item-desc-list-at-start.item-table.html b/tests/rustdoc/item-desc-list-at-start.item-table.html
index cff4f816529..89b4ac640f2 100644
--- a/tests/rustdoc/item-desc-list-at-start.item-table.html
+++ b/tests/rustdoc/item-desc-list-at-start.item-table.html
@@ -1 +1 @@
-<ul class="item-table"><li><div class="item-name"><a class="constant" href="constant.MY_CONSTANT.html" title="constant item_desc_list_at_start::MY_CONSTANT">MY_<wbr />CONSTANT</a></div><div class="desc docblock-short">Groups: <code>SamplePatternSGIS</code>, <code>SamplePatternEXT</code></div></li></ul>
\ No newline at end of file
+<dl class="item-table"><dt><a class="constant" href="constant.MY_CONSTANT.html" title="constant item_desc_list_at_start::MY_CONSTANT">MY_<wbr />CONSTANT</a></dt><dd>Groups: <code>SamplePatternSGIS</code>, <code>SamplePatternEXT</code></dd></dl>
\ No newline at end of file
diff --git a/tests/rustdoc/item-desc-list-at-start.rs b/tests/rustdoc/item-desc-list-at-start.rs
index fbcc36066f1..7c2b31c9460 100644
--- a/tests/rustdoc/item-desc-list-at-start.rs
+++ b/tests/rustdoc/item-desc-list-at-start.rs
@@ -1,7 +1,8 @@
 //@ has item_desc_list_at_start/index.html
-//@ count - '//ul[@class="item-table"]/li/div/li' 0
-//@ count - '//ul[@class="item-table"]/li' 1
-//@ snapshot item-table - '//ul[@class="item-table"]'
+//@ count - '//dl[@class="item-table"]/dd//ul' 0
+//@ count - '//dl[@class="item-table"]/dd//li' 0
+//@ count - '//dl[@class="item-table"]/dd' 1
+//@ snapshot item-table - '//dl[@class="item-table"]'
 
 // based on https://docs.rs/gl_constants/0.1.1/src/gl_constants/lib.rs.html#16
 
diff --git a/tests/rustdoc/macro-rules-broken-intra-doc-106142.rs b/tests/rustdoc/macro-rules-broken-intra-doc-106142.rs
deleted file mode 100644
index 0d146a3c5cd..00000000000
--- a/tests/rustdoc/macro-rules-broken-intra-doc-106142.rs
+++ /dev/null
@@ -1,17 +0,0 @@
-// https://github.com/rust-lang/rust/issues/106142
-#![crate_name="foo"]
-
-//@ has 'foo/a/index.html'
-//@ count 'foo/a/index.html' '//ul[@class="item-table"]//li//a' 1
-
-#![allow(rustdoc::broken_intra_doc_links)]
-
-pub mod a {
-    /// [`m`]
-    pub fn f() {}
-
-    #[macro_export]
-    macro_rules! m {
-        () => {};
-    }
-}
diff --git a/tests/rustdoc/nested-items-issue-111415.rs b/tests/rustdoc/nested-items-issue-111415.rs
index a5cd3ca0b1a..79dc2b0378f 100644
--- a/tests/rustdoc/nested-items-issue-111415.rs
+++ b/tests/rustdoc/nested-items-issue-111415.rs
@@ -10,7 +10,7 @@
 //@ has - '//*[@id="main-content"]/*[@class="section-header"]' 'Functions'
 //@ has - '//*[@id="main-content"]/*[@class="section-header"]' 'Traits'
 // Checking that there are only three items.
-//@ count - '//*[@id="main-content"]//*[@class="item-name"]' 3
+//@ count - '//*[@id="main-content"]//dt' 3
 //@ has - '//*[@id="main-content"]//a[@href="struct.Bar.html"]' 'Bar'
 //@ has - '//*[@id="main-content"]//a[@href="fn.foo.html"]' 'foo'
 //@ has - '//*[@id="main-content"]//a[@href="trait.Foo.html"]' 'Foo'
diff --git a/tests/rustdoc/overlapping-reexport-105735-2.rs b/tests/rustdoc/overlapping-reexport-105735-2.rs
index 9f823ec5923..fa43924ff4e 100644
--- a/tests/rustdoc/overlapping-reexport-105735-2.rs
+++ b/tests/rustdoc/overlapping-reexport-105735-2.rs
@@ -5,8 +5,8 @@
 #![no_std]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="item-name"]/a[@class="type"]' 'AtomicU8'
-//@ has - '//*[@class="item-name"]/a[@class="constant"]' 'AtomicU8'
+//@ has - '//dt/a[@class="type"]' 'AtomicU8'
+//@ has - '//dt/a[@class="constant"]' 'AtomicU8'
 // We also ensure we don't have another item displayed.
 //@ count - '//*[@id="main-content"]/*[@class="section-header"]' 2
 //@ has - '//*[@id="main-content"]/*[@class="section-header"]' 'Type Aliases'
diff --git a/tests/rustdoc/overlapping-reexport-105735.rs b/tests/rustdoc/overlapping-reexport-105735.rs
index 2a2d0fa9830..d1b5c0b6749 100644
--- a/tests/rustdoc/overlapping-reexport-105735.rs
+++ b/tests/rustdoc/overlapping-reexport-105735.rs
@@ -5,8 +5,8 @@
 #![no_std]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="item-name"]/a[@class="struct"]' 'AtomicU8'
-//@ has - '//*[@class="item-name"]/a[@class="constant"]' 'AtomicU8'
+//@ has - '//dt/a[@class="struct"]' 'AtomicU8'
+//@ has - '//dt/a[@class="constant"]' 'AtomicU8'
 // We also ensure we don't have another item displayed.
 //@ count - '//*[@id="main-content"]/*[@class="section-header"]' 2
 //@ has - '//*[@id="main-content"]/*[@class="section-header"]' 'Structs'
diff --git a/tests/rustdoc/pub-use-root-path-95873.rs b/tests/rustdoc/pub-use-root-path-95873.rs
index e3d5ee6e315..8e4fd9e8d50 100644
--- a/tests/rustdoc/pub-use-root-path-95873.rs
+++ b/tests/rustdoc/pub-use-root-path-95873.rs
@@ -1,5 +1,5 @@
 // https://github.com/rust-lang/rust/issues/95873
 #![crate_name = "foo"]
 
-//@ has foo/index.html "//*[@class='item-name']" "pub use ::std as x;"
+//@ has foo/index.html "//dt" "pub use ::std as x;"
 pub use ::std as x;
diff --git a/tests/rustdoc/reexport-cfg.rs b/tests/rustdoc/reexport-cfg.rs
index 7270da3d678..73b66824316 100644
--- a/tests/rustdoc/reexport-cfg.rs
+++ b/tests/rustdoc/reexport-cfg.rs
@@ -13,18 +13,18 @@ mod foo {
 }
 
 //@ has 'foo/index.html'
-//@ has - '//*[@class="item-name"]' 'BabarNon-lie'
+//@ has - '//dt' 'BabarNon-lie'
 #[cfg(not(feature = "lie"))]
 pub use crate::foo::Bar as Babar;
 
-//@ has - '//*[@class="item-name"]' 'Babar2Non-cake'
+//@ has - '//dt' 'Babar2Non-cake'
 #[doc(cfg(not(feature = "cake")))]
 pub use crate::foo::Bar2 as Babar2;
 
-//@ has - '//*[@class="item-table"]/li' 'pub use crate::Babar as Elephant;Non-robot'
+//@ has - '//*[@class="item-table reexports"]/dt' 'pub use crate::Babar as Elephant;Non-robot'
 #[cfg(not(feature = "robot"))]
 pub use crate::Babar as Elephant;
 
-//@ has - '//*[@class="item-table"]/li' 'pub use crate::Babar2 as Elephant2;Non-cat'
+//@ has - '//*[@class="item-table reexports"]/dt' 'pub use crate::Babar2 as Elephant2;Non-cat'
 #[doc(cfg(not(feature = "cat")))]
 pub use crate::Babar2 as Elephant2;
diff --git a/tests/rustdoc/reexport-check.rs b/tests/rustdoc/reexport-check.rs
index 0f4e203d1d3..fc10e3aadd0 100644
--- a/tests/rustdoc/reexport-check.rs
+++ b/tests/rustdoc/reexport-check.rs
@@ -8,13 +8,13 @@ extern crate reexport_check;
 #[allow(deprecated, deprecated_in_future)]
 pub use std::i32;
 //@ !has 'foo/index.html' '//code' 'pub use self::string::String;'
-//@ has 'foo/index.html' '//div[@class="item-name"]' 'String'
+//@ has 'foo/index.html' '//dt' 'String'
 pub use std::string::String;
 
 // i32 is deprecated, String is not
 //@ count 'foo/index.html' '//span[@class="stab deprecated"]' 1
 
-//@ has 'foo/index.html' '//div[@class="desc docblock-short"]' 'Docs in original'
+//@ has 'foo/index.html' '//dd' 'Docs in original'
 // this is a no-op, but shows what happens if there's an attribute that isn't a doc-comment
 #[doc(inline)]
 pub use reexport_check::S;
diff --git a/tests/rustdoc/reexport-doc-hidden-inside-private.rs b/tests/rustdoc/reexport-doc-hidden-inside-private.rs
index fac928fc2a3..8e194ef74fb 100644
--- a/tests/rustdoc/reexport-doc-hidden-inside-private.rs
+++ b/tests/rustdoc/reexport-doc-hidden-inside-private.rs
@@ -12,5 +12,5 @@ mod private_module {
 //@ has - '//*[@id="reexport.Foo"]/code' 'pub use crate::private_module::Public as Foo;'
 pub use crate::private_module::Public as Foo;
 // Glob re-exports with no visible items should not be displayed.
-//@ count - '//*[@class="item-table"]/li' 1
+//@ count - '//*[@class="item-table reexports"]/dt' 1
 pub use crate::private_module::*;
diff --git a/tests/rustdoc/reexport-of-reexport-108679.rs b/tests/rustdoc/reexport-of-reexport-108679.rs
index 5c1b4bcbd83..0d2faf71d32 100644
--- a/tests/rustdoc/reexport-of-reexport-108679.rs
+++ b/tests/rustdoc/reexport-of-reexport-108679.rs
@@ -25,5 +25,6 @@ pub mod a {
 //@ has - '//*[@id="main-content"]//*[@id="reexport.A"]' 'pub use self::a::A;'
 //@ has - '//*[@id="main-content"]//*[@id="reexport.B"]' 'pub use self::a::B;'
 // Should only contain "Modules" and "Re-exports".
-//@ count - '//*[@id="main-content"]//*[@class="item-table"]' 2
+//@ count - '//*[@id="main-content"]//*[@class="item-table"]' 1
+//@ count - '//*[@id="main-content"]//*[@class="item-table reexports"]' 1
 pub use self::a::{A, B};
diff --git a/tests/rustdoc/reexport-trait-from-hidden-111064.rs b/tests/rustdoc/reexport-trait-from-hidden-111064.rs
index 84ec818ef33..8b9ad7616ea 100644
--- a/tests/rustdoc/reexport-trait-from-hidden-111064.rs
+++ b/tests/rustdoc/reexport-trait-from-hidden-111064.rs
@@ -5,7 +5,7 @@
 #![crate_name = "foo"]
 
 //@ has 'foo/index.html'
-//@ has - '//*[@id="main-content"]//*[@class="item-name"]/a[@href="trait.Foo.html"]' 'Foo'
+//@ has - '//*[@id="main-content"]//dt/a[@href="trait.Foo.html"]' 'Foo'
 
 //@ has 'foo/trait.Foo.html'
 //@ has - '//*[@id="main-content"]//*[@class="code-header"]' 'fn test()'
diff --git a/tests/rustdoc/short-docblock.rs b/tests/rustdoc/short-docblock.rs
index c80a5025ebe..fa0af85696a 100644
--- a/tests/rustdoc/short-docblock.rs
+++ b/tests/rustdoc/short-docblock.rs
@@ -1,7 +1,7 @@
 #![crate_name = "foo"]
 
-//@ has foo/index.html '//*[@class="desc docblock-short"]' 'fooo'
-//@ !has foo/index.html '//*[@class="desc docblock-short"]/h1' 'fooo'
+//@ has foo/index.html '//dd' 'fooo'
+//@ !has foo/index.html '//dd//h1' 'fooo'
 
 //@ has foo/fn.foo.html '//h2[@id="fooo"]' 'fooo'
 //@ has foo/fn.foo.html '//h2[@id="fooo"]/a[@href="#fooo"]' 'ยง'
@@ -10,8 +10,8 @@
 /// foo
 pub fn foo() {}
 
-//@ has foo/index.html '//*[@class="desc docblock-short"]' 'mooood'
-//@ !has foo/index.html '//*[@class="desc docblock-short"]/h2' 'mooood'
+//@ has foo/index.html '//dd' 'mooood'
+//@ !has foo/index.html '//dd//h2' 'mooood'
 
 //@ has foo/foo/index.html '//h3[@id="mooood"]' 'mooood'
 //@ has foo/foo/index.html '//h3[@id="mooood"]/a[@href="#mooood"]' 'ยง'
@@ -20,8 +20,7 @@ pub fn foo() {}
 /// foo mod
 pub mod foo {}
 
-//@ has foo/index.html '//*[@class="desc docblock-short"]/a[@href=\
-//                      "https://nougat.world"]/code' 'nougat'
+//@ has foo/index.html '//dd/a[@href="https://nougat.world"]/code' 'nougat'
 
 /// [`nougat`](https://nougat.world)
 pub struct Bar;
diff --git a/tests/rustdoc/stability.rs b/tests/rustdoc/stability.rs
index 550eb0bc137..b74abb0e0ba 100644
--- a/tests/rustdoc/stability.rs
+++ b/tests/rustdoc/stability.rs
@@ -5,9 +5,9 @@
 #![stable(feature = "core", since = "1.6.0")]
 
 //@ has stability/index.html
-//@ has - '//ul[@class="item-table"]/li[1]//a' AaStable
-//@ has - '//ul[@class="item-table"]/li[2]//a' ZzStable
-//@ has - '//ul[@class="item-table"]/li[3]//a' Unstable
+//@ has - '//dl[@class="item-table"]/dt[1]//a' AaStable
+//@ has - '//dl[@class="item-table"]/dt[2]//a' ZzStable
+//@ has - '//dl[@class="item-table"]/dt[3]//a' Unstable
 
 #[stable(feature = "rust2", since = "2.2.2")]
 pub struct AaStable;
diff --git a/tests/rustdoc/staged-api-deprecated-unstable-32374.rs b/tests/rustdoc/staged-api-deprecated-unstable-32374.rs
index 556b6fb61ac..1021ce86df0 100644
--- a/tests/rustdoc/staged-api-deprecated-unstable-32374.rs
+++ b/tests/rustdoc/staged-api-deprecated-unstable-32374.rs
@@ -4,11 +4,9 @@
 #![unstable(feature = "test", issue = "32374")]
 #![crate_name="issue_32374"]
 
-//@ matches issue_32374/index.html '//*[@class="item-name"]/span[@class="stab deprecated"]' \
-//      'Deprecated'
-//@ matches issue_32374/index.html '//*[@class="item-name"]/span[@class="stab unstable"]' \
-//      'Experimental'
-//@ matches issue_32374/index.html '//*[@class="desc docblock-short"]/text()' 'Docs'
+//@ matches issue_32374/index.html '//dt/span[@class="stab deprecated"]' 'Deprecated'
+//@ matches issue_32374/index.html '//dt/span[@class="stab unstable"]' 'Experimental'
+//@ matches issue_32374/index.html '//dd/text()' 'Docs'
 
 //@ has issue_32374/struct.T.html '//*[@class="stab deprecated"]/span' '๐Ÿ‘Ž'
 //@ has issue_32374/struct.T.html '//*[@class="stab deprecated"]/span' \
diff --git a/tests/rustdoc/summary-header-46377.rs b/tests/rustdoc/summary-header-46377.rs
index 11445f0dad6..c84f3a65cfb 100644
--- a/tests/rustdoc/summary-header-46377.rs
+++ b/tests/rustdoc/summary-header-46377.rs
@@ -1,6 +1,6 @@
 // https://github.com/rust-lang/rust/issues/46377
 #![crate_name="foo"]
 
-//@ has 'foo/index.html' '//*[@class="desc docblock-short"]' 'Check out this struct!'
+//@ has 'foo/index.html' '//dd' 'Check out this struct!'
 /// # Check out this struct!
 pub struct SomeStruct;