Mercurial > hg
annotate tests/test-check-rust-format.t @ 51737:48eb51494a7a
rustfmt: update expected Rust edition
In this case it doesn't change anything, but we've been using 2021 for a
while now.
author | Raphaël Gomès <rgomes@octobus.net> |
---|---|
date | Mon, 29 Jul 2024 10:07:53 +0200 |
parents | c8188b10cf43 |
children |
rev | line source |
---|---|
43819
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
1 #require rustfmt test-repo |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
2 |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
3 $ . "$TESTDIR/helpers-testrepo.sh" |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
4 |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
5 $ cd "$TESTDIR"/.. |
48742
090346b095fb
hghave: update rustfmt criterion
Raphaël Gomès <rgomes@octobus.net>
parents:
48297
diff
changeset
|
6 |
090346b095fb
hghave: update rustfmt criterion
Raphaël Gomès <rgomes@octobus.net>
parents:
48297
diff
changeset
|
7 Warning: Keep this in sync with hghave.py |
51736
c8188b10cf43
hghave: update expected rustfmt version
Raphaël Gomès <rgomes@octobus.net>
parents:
48742
diff
changeset
|
8 $ RUSTFMT=$(rustup which --toolchain nightly-2024-07-16 rustfmt) |
43819
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
9 $ for f in `testrepohg files 'glob:**/*.rs'` ; do |
51737
48eb51494a7a
rustfmt: update expected Rust edition
Raphaël Gomès <rgomes@octobus.net>
parents:
51736
diff
changeset
|
10 > $RUSTFMT --check --edition=2021 --unstable-features --color=never $f |
43819
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
11 > done |