Skip to content

Commit 1f448e4

Browse files
authoredSep 25, 2023
fix(tests): Fix cargo test with default features. (#294)
A couple of tests require `fancy-no-backtrace`, so mark them accordingly.
1 parent db0b7e4 commit 1f448e4

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed
 

‎tests/test_diagnostic_source_macro.rs

+3
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ fn test_diagnostic_source() {
7575
assert!(error.diagnostic_source().is_some());
7676
}
7777

78+
#[cfg(feature = "fancy-no-backtrace")]
7879
#[test]
7980
fn test_diagnostic_source_pass_extra_info() {
8081
let diag = TestBoxedError(Box::new(SourceError {
@@ -106,6 +107,7 @@ fn test_diagnostic_source_pass_extra_info() {
106107
assert_eq!(expected, out);
107108
}
108109

110+
#[cfg(feature = "fancy-no-backtrace")]
109111
#[test]
110112
fn test_diagnostic_source_is_output() {
111113
let diag = TestStructError {
@@ -147,6 +149,7 @@ struct NestedError {
147149
the_other_err: Box<dyn Diagnostic>,
148150
}
149151

152+
#[cfg(feature = "fancy-no-backtrace")]
150153
#[test]
151154
fn test_nested_diagnostic_source_is_output() {
152155
let inner_error = TestStructError {

0 commit comments

Comments
 (0)
Please sign in to comment.