Implement D402 for pydocstyle (#403)

This commit is contained in:
Charlie Marsh 2022-10-11 13:19:56 -04:00 committed by GitHub
parent 71802f8861
commit 8868f57a74
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 64 additions and 12 deletions

View file

@ -1104,6 +1104,18 @@ mod tests {
Ok(())
}
#[test]
fn d402() -> Result<()> {
let mut checks = check_path(
Path::new("./resources/test/fixtures/D.py"),
&settings::Settings::for_rule(CheckCode::D402),
&fixer::Mode::Generate,
)?;
checks.sort_by_key(|check| check.location);
insta::assert_yaml_snapshot!(checks);
Ok(())
}
#[test]
fn d403() -> Result<()> {
let mut checks = check_path(