#framework #unit-testing #benchmark #built #micro-benchmarking #bencher #bench

yanked libtest

Rust's built in unit-test and micro-benchmarking framework

1 unstable release

0.0.1 Mar 3, 2019

#6 in #bencher

Download history 23/week @ 2024-07-28 10/week @ 2024-08-11 10/week @ 2024-08-18 6/week @ 2024-08-25 10/week @ 2024-09-01 26/week @ 2024-09-08 33/week @ 2024-09-15 83/week @ 2024-09-22 38/week @ 2024-09-29 32/week @ 2024-10-06 46/week @ 2024-10-13 62/week @ 2024-10-20 23/week @ 2024-10-27 48/week @ 2024-11-03 34/week @ 2024-11-10

173 downloads per month
Used in tarpc-bincode-transport

MIT/Apache

190KB
4.5K SLoC

Note: This repository is no longer in use. The test crate lives in the rust-lang/rust repository.


Build Status Build Status Latest Version docs

libtest - Rust's built-in unit-testing and benchmarking framework

See The Rust Programming Language chapter on Testing.

Platform support

  • "build" shows whether the library compiles
  • "run" shows whether the full test-suite passes
Target Build Run
aarch64-linux-android
aarch64-unknown-linux-gnu
arm-linux-androideabi
arm-unknown-linux-gnueabi
arm-unknown-linux-musleabi
armv7-linux-androideabi
armv7-unknown-linux-gnueabihf
armv7-unknown-linux-musleabihf
i586-unknown-linux-gnu
i586-unknown-linux-musl
i686-linux-android
i686-pc-windows-gnu
i686-apple-darwin
i686-unknown-freebsd
i686-unknown-linux-gnu
i686-unknown-linux-musl
mips-unknown-linux-gnu
mips64-unknown-linux-gnuabi64
mips64el-unknown-linux-gnuabi64
mipsel-unknown-linux-gnu
powerpc-unknown-linux-gnu
powerpc64-unknown-linux-gnu
powerpc64le-unknown-linux-gnu
sparc64-unknown-linux-gnu
s390x-unknown-linux-gnu
x86_64-apple-darwin
x86_64-sun-solaris
x86_64-linux-android
x86_64-pc-windows-gnu
x86_64-pc-windows-msvc
x86_64-unknown-freebsd
x86_64-unknown-linux-gnu
x86_64-unknown-linux-musl
x86_64-unknown-netbsd

License

This project is licensed under either of

at your option.

Contributing

We welcome all people who want to contribute.

Contributions in any form (issues, pull requests, etc.) to this project must adhere to Rust's Code of Conduct.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in libtest by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.


lib.rs:

Support code for rustc's built in unit-test and micro-benchmarking framework.

Almost all user code will only be interested in Bencher and black_box. All other interactions (such as writing tests and benchmarks themselves) should be done via the #[test] and #[bench] attributes.

See the Testing Chapter of the book for more details.

Dependencies

~1.5MB
~20K SLoC