#logging #tracing-test #testing-macro #fluent #ansi-colors #tracing-macro

dev n0-tracing-test

Helper functions and macros that allow for easier testing of crates that use tracing

1 unstable release

0.3.0 Dec 18, 2025

#160 in Testing

Download history 222/week @ 2025-12-14 166/week @ 2025-12-21 69/week @ 2025-12-28 815/week @ 2026-01-04 276/week @ 2026-01-11 548/week @ 2026-01-18 706/week @ 2026-01-25 675/week @ 2026-02-01 616/week @ 2026-02-08 664/week @ 2026-02-15 704/week @ 2026-02-22

2,664 downloads per month
Used in 6 crates

MIT license

17KB
106 lines

n0-tracing-test

Build status Crates.io Version Crates.io Downloads

A fork of tracing-test

We forked because we want colored output on the terminal. See the list of PRs for other changes from upstream.


This crate provides an easy way to enable logging in tests that use tracing, even if they're async. Additionally, it adds a way to assert that certain things were logged.

To enable ANSI colors and support for filtering with RUST_LOG in the terminal output, enable the pretty-log-printing feature (enabled by default).

Similar crates:

Docs / Usage / Example

See https://docs.rs/n0-tracing-test/.

License

Copyright © 2020-2023 Threema GmbH, Danilo Bargen and Contributors.

Copyright © 2025 N0, INC.

Licensed under either of

Contribution

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

Dependencies

~8–12MB
~142K SLoC