]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #48913 - Mark-Simulacrum:rustbuild-test, r=alexcrichton
authorbors <bors@rust-lang.org>
Wed, 4 Apr 2018 15:38:10 +0000 (15:38 +0000)
committerbors <bors@rust-lang.org>
Wed, 4 Apr 2018 15:38:10 +0000 (15:38 +0000)
Add tests to rustbuild

In order to run tests, we cfg out various parts of rustbuild. Generally
speaking, these are filesystem and process-spawning operations. Then, rustbuild
is run "as normal" and the various steps that where run are retrieved from the
cache and checked against the expected results.

Note that this means that the current implementation primarily tests "what" we
build, but doesn't actually test that what we build *will* build. In other
words, it doesn't do any form of dependency verification for any crate. This is
possible to implement, but is considered future work.

This implementation strives to cfg out as little code as possible; it also does
not currently test anywhere near all of rustbuild. The current tests are also
not checked for "correctness," rather, they simply represent what we do as of
this commit, which may be wrong.

Test cases are drawn from the old implementation of rustbuild, though the
expected results may vary.

r? @alexcrichton


Trivial merge