Skip to content
This repository was archived by the owner on Aug 16, 2021. It is now read-only.

Commit 5d1f3c7

Browse files
authored
Resolve failing tests (#279)
* Minimum supported rust is now 1.13.0 (without backtrace support) * Minimum supported rust is 1.32.0 for backtrace support * specify chainederror backtrace
1 parent 0653e6a commit 5d1f3c7

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

.travis.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ rust:
66
# Oldest supported version for all features.
77
# Use of https://github.com/rust-lang/rfcs/pull/16
88
# rustc-demangle uses feature `rename-dependency`
9-
- 1.31.0
9+
- 1.32.0
1010
# Oldest supported version as dependency, with no features, tests, or examples.
11-
- 1.10.0
11+
- 1.13.0
1212

1313
sudo: false
1414
cache: cargo
@@ -26,7 +26,7 @@ before_script:
2626
2727
script:
2828
- travis-cargo build -- $FEATURES
29-
- travis-cargo --skip 1.10.0 test -- $FEATURES
29+
- travis-cargo --skip 1.13.0 test -- $FEATURES
3030

3131
after_success:
3232
- travis-cargo --only stable doc
@@ -44,4 +44,4 @@ env:
4444
matrix:
4545
exclude:
4646
- env: FEATURES=--features=backtrace
47-
rust: 1.10.0
47+
rust: 1.13.0

src/lib.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -647,14 +647,13 @@ impl<'a, T> fmt::Display for DisplayChain<'a, T>
647647
where T: ChainedError
648648
{
649649
fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result {
650-
// Keep `try!` for 1.10 support
651650
writeln!(fmt, "Error: {}", self.0)?;
652651

653652
for e in self.0.iter().skip(1) {
654653
writeln!(fmt, "Caused by: {}", e)?;
655654
}
656655

657-
if let Some(backtrace) = self.0.backtrace() {
656+
if let Some(backtrace) = ChainedError::backtrace(self.0) {
658657
writeln!(fmt, "{:?}", backtrace)?;
659658
}
660659

0 commit comments

Comments
 (0)