diff options
| author | Philip Munksgaard <pmunksgaard@gmail.com> | 2018-10-05 19:08:52 +0200 |
|---|---|---|
| committer | Philip Munksgaard <pmunksgaard@gmail.com> | 2018-10-05 19:13:37 +0200 |
| commit | 5f8dc0ddf47274e0a98111edc816b825484d0d1a (patch) | |
| tree | baeba3df150af5a0b53cd75d91e445098da62f65 /src/test/rustdoc | |
| parent | 46ccce0803386db3d7c0dbdd30d31474889b64a0 (diff) | |
| download | rust-5f8dc0ddf47274e0a98111edc816b825484d0d1a.tar.gz rust-5f8dc0ddf47274e0a98111edc816b825484d0d1a.zip | |
Fix unneeded-trait-implementations-title test
The `@!has` command does not support specifying just a PATH and an XPATH. That means that the previous test searched for the literal string `//h2[@id="implementations"]` within the generated output, which obviously didn't exist. Even after adding a trait implementation, the test still passed. The correct way to check for the existence of a DOM element with the id `implementations` is to use the `@count` keyword.
Diffstat (limited to 'src/test/rustdoc')
| -rw-r--r-- | src/test/rustdoc/unneeded-trait-implementations-title.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/test/rustdoc/unneeded-trait-implementations-title.rs b/src/test/rustdoc/unneeded-trait-implementations-title.rs index 2c074179e32..c87b533b9d4 100644 --- a/src/test/rustdoc/unneeded-trait-implementations-title.rs +++ b/src/test/rustdoc/unneeded-trait-implementations-title.rs @@ -12,4 +12,4 @@ pub struct Bar; -// @!has foo/struct.Bar.html '//*[@id="implementations"]' +// @count foo/struct.Bar.html '//*[@id="implementations"]' 0 |
