`@!has` (and `@!matches`) with two arguments used to treat the second argument as a literal string of HTML code. Now, that feature has been renamed into `@!hasraw` (and `@!matchesraw`), and the arity-2 `@!has` version is an error. These uses thought the second argument was being treated as an XPath, as with the arity-3 version, but in fact was being treated as literal HTML. Because these were checking for the *absence* of the string, the tests silently did nothing -- an XPath string won't ever be showing up in the test's generated HTML!
18 lines
603 B
Rust
18 lines
603 B
Rust
// compile-flags: -Z force-unstable-if-unmarked
|
|
|
|
// Check that the unstable marker is not added for "rustc_private".
|
|
|
|
// @!matches internal/index.html \
|
|
// '//*[@class="item-right docblock-short"]/span[@class="stab unstable"]' \
|
|
// ''
|
|
// @!matches internal/index.html \
|
|
// '//*[@class="item-right docblock-short"]/span[@class="stab internal"]' \
|
|
// ''
|
|
// @matches - '//*[@class="item-right docblock-short"]' 'Docs'
|
|
|
|
// @!has internal/struct.S.html '//*[@class="stab unstable"]' ''
|
|
// @!has internal/struct.S.html '//*[@class="stab internal"]' ''
|
|
/// Docs
|
|
pub struct S;
|
|
|
|
fn main() {}
|