Skip to content

Commit

Permalink
Error if the NURSERY selector is used with preview (#9682)
Browse files Browse the repository at this point in the history
Changes our warning for combined use of `--preview` and `--select
NURSERY` to a hard error.

This should go out _before_ #9680 where we will ban use of `NURSERY`
outside of preview as well (see #9683).

Part of #7992
  • Loading branch information
zanieb authored Jan 29, 2024
1 parent 05a2f52 commit 4ccbacd
Show file tree
Hide file tree
Showing 2 changed files with 89 additions and 69 deletions.
9 changes: 3 additions & 6 deletions crates/ruff/tests/integration_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -878,15 +878,12 @@ fn nursery_group_selector_preview_enabled() {
assert_cmd_snapshot!(cmd
.pass_stdin("I=42\n"), @r###"
success: false
exit_code: 1
exit_code: 2
----- stdout -----
-:1:1: CPY001 Missing copyright notice at top of file
-:1:2: E225 [*] Missing whitespace around operator
Found 2 errors.
[*] 1 fixable with the `--fix` option.
----- stderr -----
warning: The `NURSERY` selector has been deprecated.
ruff failed
Cause: The `NURSERY` selector is deprecated and cannot be used with preview mode enabled.
"###);
}

Expand Down
Loading

0 comments on commit 4ccbacd

Please sign in to comment.