Update doc_auto_cfg test

This commit is contained in:
Guillaume Gomez 2022-01-13 15:50:21 +01:00
parent 682ef4db80
commit fd005f53c2

View File

@ -3,6 +3,12 @@
#![crate_name = "foo"]
// @has foo/fn.foo.html
// @has - '//*[@class="item-info"]/*[@class="stab portability"]' 'non-test'
#[cfg(not(test))]
// @has - '//*[@class="item-info"]/*[@class="stab portability"]' 'non-doctest'
#[cfg(not(doctest))]
pub fn foo() {}
// @has foo/fn.bar.html
// @has - '//*[@class="item-info"]/*[@class="stab portability"]' 'doc'
// @!has - '//*[@class="item-info"]/*[@class="stab portability"]' 'test'
#[cfg(any(test, doc))]
pub fn bar() {}