Mercurial > hg
annotate tests/test-check-rust-format.t @ 44013:992f0d6e7f33
rust-index: use the new method in shortesthexnodeidprefix
This code can now run with both a Rust or a C index.
Differential Revision: https://phab.mercurial-scm.org/D7659
author | Georges Racinet <georges.racinet@octobus.net> |
---|---|
date | Wed, 11 Dec 2019 18:10:20 +0100 |
parents | e8a3bbffdc7d |
children | f44a7d8660ea |
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"/.. |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
6 $ RUSTFMT=$(rustup which --toolchain nightly rustfmt) |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
7 $ for f in `testrepohg files 'glob:**/*.rs'` ; do |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
8 > $RUSTFMT --check --unstable-features --color=never $f |
e8a3bbffdc7d
tests: add test for Rust formatting
Gregory Szorc <gregory.szorc@gmail.com>
parents:
diff
changeset
|
9 > done |