Skip to content

Commit

Permalink
test: update for term fallout
Browse files Browse the repository at this point in the history
  • Loading branch information
emberian committed May 16, 2014
1 parent 7bf1de5 commit 3af7755
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/libtest/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ pub enum TestResult {
}

enum OutputLocation<T> {
Pretty(term::Terminal<T>),
Pretty(~term::Terminal<~Writer:Send>:Send),
Raw(T),
}

Expand All @@ -472,10 +472,11 @@ impl<T: Writer> ConsoleTestState<T> {
Some(ref path) => Some(try!(File::create(path))),
None => None
};
let out = match term::Terminal::new(io::stdio::stdout_raw()) {
Err(_) => Raw(io::stdio::stdout_raw()),
Ok(t) => Pretty(t)
let out = match term::stdout() {
None => Raw(io::stdio::stdout_raw()),
Some(t) => Pretty(t)
};

Ok(ConsoleTestState {
out: out,
log_out: log_out,
Expand Down

0 comments on commit 3af7755

Please sign in to comment.