File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -23,7 +23,14 @@ to create regressions. Any tests you can add are very much appreciated.
2323The tests can be run with ` cargo test ` . This does a number of things:
2424* runs the unit tests for a number of internal functions;
2525* makes sure that rustfmt run on every file in ` ./tests/source/ ` is equal to its
26- associated file in ` ./tests/target/ ` ;
26+ associated file in ` ./tests/target/ ` ; this catches
27+ * unexpected formatting differences from changes to rustfmt
28+ * non-idempotency in formatting even when the file copy in ` target/ ` is
29+ already in the canonical expected format. That is, if ` source_start ` is
30+ the starting formatting and ` source_canonical ` is the expected canonical
31+ formatting, catch cases where there is a converging sequence
32+ ` source_start -> source_1 -> ... -> source_canonical ` that takes multiple
33+ rustfmt runs.
2734* runs idempotence tests on the files in ` ./tests/target/ ` . These files should
2835 not be changed by rustfmt;
2936* checks that rustfmt's code is not changed by running on itself. This ensures
You can’t perform that action at this time.
0 commit comments