Skip to content

Commit e8bc04e

Browse files
committed
Use XPATH notation to match against flattened nodes
The generated code would look like `<code>impl <a href="...">Foo</a></code>` which the plain text matcher doesn't match. But by using the XPATH notation, the nodes are flattened and we can correctly assert that `impl Foo` does not occur in the generated docs.
1 parent 28596ad commit e8bc04e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/test/rustdoc/hidden-methods.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,12 @@ pub mod hidden {
2828

2929
// @has foo/struct.Foo.html
3030
// @!has - 'Methods'
31-
// @!has - 'impl Foo'
31+
// @!has - '//code' 'impl Foo'
3232
// @!has - 'this_should_be_hidden'
3333
pub use hidden::Foo;
3434

3535
// @has foo/struct.Bar.html
3636
// @!has - 'Methods'
37-
// @!has - 'impl Bar'
37+
// @!has - '//code' 'impl Bar'
3838
// @!has - 'this_should_be_hidden'
3939
pub use hidden::Bar;

0 commit comments

Comments
 (0)