Do you know why so many targets are red?
So right now I’m running all these tests on all the non-windows targets:
- Basic unit testing: #[test], #[should_panic]
- unit tests of each standard crate (e.g. libcollectionstest)
The current HEAD of the repository now runs all these tests even if one of them fails (I basically
make's “keep going” flag) and report at the end which tests failed (if any). That
report looks like this:
That’s for the
So far I’m seeing the targets fail for these reasons:
catch_panic: this doesn’t work on the i686-musl target. This is a legit failure and has been
reported to the rust-lang/rust issue tracker.
- libc_test: these seem to be due to the glibc/toolchain version I’m using. Note that the test
suite doesn’t actually fail, instead it doesn’t even compile (compiling libc-test involves
compiling an auto-generated C file, that file doesn’t compile). Most of the targets that appear as
failing in my repo pass the test suite on the libc repo, but the libc repo is using older
glibcs/toolchains. cf. rust-lang/libc#23 and rust-lang/libc#357
- QEMU is broken for this arch: This is the case for powerpc64le. qemu-ppc64le segfaults when I try
to run any binary for this architecture. cf. Debian bug
- libstd’s unit tests segfault: This only happens on cross targets whose unit tests are run under
QEMU. And I think these may be false positive caused by QEMU limitation of handling several threads.
Because I’ve tested a few of these targets locally (also under QEMU) but running only the test
that fails (instead of the whole test suite) and on some runs the test passes and on some runs the
test segfaults. NOTE that in all cases (also in the repository), I always run unit tests with
limit the number of unit tests that runs concurrently to one but a single unit test may still
spawn several threads.
- libstd’s unit tests hang: Pretty much the same as above. I think this may be caused by QEMU.
These are the libstd unit tests I’ve seen fail so far:
I’ve yet to dig deeper into these unit tests to figure out which are real failures and which are false
positives with 100% certainty though.
The good news is that all the other standard crates (libcoretest, librand, etc) pass their test
suites with 100% success on all the targets .
and why the badge says the build is passing
I think you were observing the build result of a branch that was not yet merged. The badge is no
longer green now :-).