Crates.io | tracing-test-macro |
lib.rs | tracing-test-macro |
version | 0.2.5 |
source | src |
created_at | 2020-11-19 09:24:12.151317 |
updated_at | 2024-06-02 16:23:33.398437 |
description | A procedural macro that allow for easier testing of crates that use `tracing`. Internal crate, should only be used through the `tracing-test` crate. |
homepage | |
repository | https://github.com/dbrgn/tracing-test |
max_upload_size | |
id | 313940 |
size | 20,429 |
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.
The focus is on testing the logging, not on debugging the tests. That's why the
library ensures that the logs do not depend on external state. For example, the
RUST_LOG
env variable is not used for log filtering.
Similar crates:
See https://docs.rs/tracing-test/.
Copyright © 2020-2023 Threema GmbH, Danilo Bargen and Contributors.
Licensed under either of
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.