Commit 6f8d18a
Add --dnd alias for --disable-nextest-doctest flag (mitsuhiko#822)
## Summary
Adds a shorter `--dnd` alias for the `--disable-nextest-doctest` flag to
make it easier to silence the deprecation warning during the transition
period.
This addresses the request from @ilyagr in mitsuhiko#803:
> It seems like people will pass this flag often to avoid the
deprecation warning. Perhaps give it a short version, e.g. `-D`?
After discussion, we agreed on `--dnd` as the alias.
## Changes
- Add `alias = "dnd"` to the `disable_nextest_doctest` CLI argument
- Update deprecation warning message to mention the `--dnd` alias: `Pass
'--disable-nextest-doctest' (or '--dnd') to update to this behavior now
and silence this warning.`
- Add test `test_nextest_doctest_dnd_alias_no_warning()` to verify the
alias works correctly
## Test plan
- [x] All existing tests pass (5/5 in nextest_doctest module)
- [x] New test verifies `--dnd` alias works correctly
- [x] Lints pass (cargo fmt, cargo clippy)
- [x] Manual verification: `cargo insta test --test-runner nextest
--dnd` works as expected
## Usage
Both forms work identically:
```bash
cargo insta test --test-runner nextest --disable-nextest-doctest
cargo insta test --test-runner nextest --dnd
```
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude <noreply@anthropic.com>1 parent 1061c1c commit 6f8d18a
2 files changed
+46
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
238 | 238 | | |
239 | 239 | | |
240 | 240 | | |
241 | | - | |
| 241 | + | |
242 | 242 | | |
243 | 243 | | |
244 | 244 | | |
| |||
897 | 897 | | |
898 | 898 | | |
899 | 899 | | |
900 | | - | |
| 900 | + | |
901 | 901 | | |
902 | 902 | | |
903 | 903 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
| |||
181 | 181 | | |
182 | 182 | | |
183 | 183 | | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
0 commit comments