Skip to content

Commit

Permalink
AVRO-3910: [Rust] Replace color-backtrace with better-panic for t…
Browse files Browse the repository at this point in the history
…he tests (#2596)

Signed-off-by: Martin Tzvetanov Grigorov <[email protected]>
  • Loading branch information
martin-g authored Nov 27, 2023
1 parent 8551ecd commit c53d498
Show file tree
Hide file tree
Showing 3 changed files with 109 additions and 51 deletions.
152 changes: 103 additions & 49 deletions lang/rust/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion lang/rust/avro_test_helper/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ readme = "README.md"

[dependencies]
anyhow = { default-features = false, version = "1.0.75", features = ["std"] }
color-backtrace = { default-features = false, version = "0.5.1" }
better-panic = { default-features = false, version = "0.3.0" }
ctor = { default-features = false, version = "0.2.4" }
env_logger = { default-features = false, version = "0.10.0" }
lazy_static = { default-features = false, version = "1.4.0" }
Expand Down
6 changes: 5 additions & 1 deletion lang/rust/avro_test_helper/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@ pub mod logger;
#[ctor]
fn before_all() {
// better stacktraces in tests
color_backtrace::install();
better_panic::Settings::new()
.most_recent_first(true)
.lineno_suffix(false)
.backtrace_first(true)
.install();

// enable logging in tests
logger::install();
Expand Down

0 comments on commit c53d498

Please sign in to comment.