mirror of
https://github.com/eyre-rs/eyre.git
synced 2025-09-28 13:31:29 +00:00
Add test that backtrace method exists on nightly
This commit is contained in:
parent
5ada2978c5
commit
6d0a0196eb
@ -14,4 +14,5 @@ default = ["std"]
|
||||
std = []
|
||||
|
||||
[dev-dependencies]
|
||||
rustversion = "1.0"
|
||||
thiserror = "1.0"
|
||||
|
13
tests/test_backtrace.rs
Normal file
13
tests/test_backtrace.rs
Normal file
@ -0,0 +1,13 @@
|
||||
#[rustversion::not(nightly)]
|
||||
#[ignore]
|
||||
#[test]
|
||||
fn test_backtrace() {}
|
||||
|
||||
#[rustversion::nightly]
|
||||
#[test]
|
||||
fn test_backtrace() {
|
||||
use anyhow::anyhow;
|
||||
|
||||
let error = anyhow!("oh no!");
|
||||
let _ = error.backtrace();
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user