File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -38,6 +38,7 @@ cargo +nightly fmt --all -- --check
3838
3939# avoid loop spam
4040set +x
41+
4142# make sure tests are formatted
4243
4344# some lints are sensitive to formatting, exclude some files
@@ -47,11 +48,13 @@ rustup default nightly
4748for file in ` find tests -not -path " tests/ui/methods.rs" -not -path " tests/ui/format.rs" -not -path " tests/ui/formatting.rs" -not -path " tests/ui/empty_line_after_outer_attribute.rs" -not -path " tests/ui/double_parens.rs" -not -path " tests/ui/doc.rs" -not -path " tests/ui/unused_unit.rs" | grep " \.rs$" ` ; do
4849rustfmt ${file} --check || echo " ${file} needs reformatting!" ; needs_formatting=true
4950done
51+
52+ set -x
53+
5054# switch back to master
5155rustup default master
5256
53- if [ " ${needs_reformatting} " = true ] ; then
57+ if [[ ${needs_reformatting} == true ] ] ; then
5458 echo " Tests need reformatting!"
5559 exit 2
5660fi
57- set -x
You can’t perform that action at this time.
0 commit comments