Skip to content

Commit

Permalink
Move working checks into separate test files
Browse files Browse the repository at this point in the history
  • Loading branch information
GuillaumeGomez committed Aug 16, 2021
1 parent 4ba54ff commit d4293ff
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 4 deletions.
8 changes: 8 additions & 0 deletions src/test/rustdoc-ui/doc-test-attr-pass.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
// check-pass

#![crate_type = "lib"]
#![deny(invalid_doc_attributes)]
#![doc(test(no_crate_inject))]
#![doc(test(attr(deny(warnings))))]

pub fn foo() {}
2 changes: 0 additions & 2 deletions src/test/rustdoc-ui/doc-test-attr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,5 @@
#![doc(test(a))]
//~^ ERROR unknown `doc(test)` attribute `a`
//~^^ WARN this was previously accepted by the compiler
#![doc(test(no_crate_inject))]
#![doc(test(attr(deny(warnings))))]

pub fn foo() {}
9 changes: 9 additions & 0 deletions src/test/ui/rustdoc/doc-test-attr-pass.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
// check-pass

#![crate_type = "lib"]
#![deny(invalid_doc_attributes)]
#![doc(test(no_crate_inject))]
#![doc(test(attr(deny(warnings))))]
#![doc(test())]

pub fn foo() {}
2 changes: 0 additions & 2 deletions src/test/ui/rustdoc/doc-test-attr.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,5 @@
#![doc(test(a))]
//~^ ERROR unknown `doc(test)` attribute `a`
//~^^ WARN this was previously accepted by the compiler
#![doc(test(no_crate_inject))]
#![doc(test(attr(deny(warnings))))]

pub fn foo() {}

0 comments on commit d4293ff

Please sign in to comment.