Fix tidy issues
This commit is contained in:
parent
ab112cab03
commit
987be89db3
2 changed files with 3 additions and 2 deletions
|
|
@ -245,7 +245,7 @@ declare_features! (
|
|||
(active, allocator_internals, "1.20.0", None, None),
|
||||
|
||||
// Allows using the `format_args_nl` macro.
|
||||
(active, format_args_nl, "1.29.0", None, None),
|
||||
(active, format_args_nl, "1.29.0", Some(0), None),
|
||||
|
||||
// no-tracking-issue-end
|
||||
|
||||
|
|
|
|||
|
|
@ -13,7 +13,8 @@ pub fn check(path: &Path, bad: &mut bool) {
|
|||
&mut |entry, contents| {
|
||||
let subpath = entry.path();
|
||||
if let Some("rs") = subpath.extension().and_then(|e| e.to_str()) {
|
||||
if contents.contains("#[test]") {
|
||||
let contents = contents.trim();
|
||||
if !contents.starts_with("//") && contents.contains("#[test]") {
|
||||
tidy_error!(
|
||||
bad,
|
||||
"{} contains #[test]; libcore tests must be placed inside \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue