mirror of
https://github.com/haraldh/chainerror.git
synced 2025-01-31 00:56:41 +01:00
fix tests for windows
This commit is contained in:
parent
913b38afdc
commit
3bf7fa00fb
|
@ -52,6 +52,7 @@ fn func1() -> Result<(), Box<Error>> {
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
if let Err(e) = func1() {
|
if let Err(e) = func1() {
|
||||||
|
#[cfg(not(windows))]
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
format!("\n{:?}\n", e), r#"
|
format!("\n{:?}\n", e), r#"
|
||||||
src/lib.rs:20: func1 error
|
src/lib.rs:20: func1 error
|
||||||
|
@ -149,6 +150,7 @@ fn main() {
|
||||||
eprintln!("\nThe root cause was: std::io::Error: {:#?}", ioerror);
|
eprintln!("\nThe root cause was: std::io::Error: {:#?}", ioerror);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[cfg(not(windows))]
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
format!("\n{:?}\n", e), r#"
|
format!("\n{:?}\n", e), r#"
|
||||||
src/lib.rs:47: func1 error calling func2
|
src/lib.rs:47: func1 error calling func2
|
||||||
|
@ -696,6 +698,7 @@ fn func1() -> Result<(), Box<Error>> {
|
||||||
|
|
||||||
# fn main() {
|
# fn main() {
|
||||||
# if let Err(e) = func1() {
|
# if let Err(e) = func1() {
|
||||||
|
# #[cfg(not(windows))]
|
||||||
# assert_eq!(
|
# assert_eq!(
|
||||||
# format!("\n{:?}\n", e), r#"
|
# format!("\n{:?}\n", e), r#"
|
||||||
# src/lib.rs:20: func1 error
|
# src/lib.rs:20: func1 error
|
||||||
|
|
Loading…
Reference in a new issue