Skip to content

Commit

Permalink
Rollup merge of rust-lang#86359 - fee1-dead:f64-junit-formatter, r=Jo…
Browse files Browse the repository at this point in the history
…hnTitor

Use as_secs_f64 in JunitFormatter

cc ``@andoriyu``
  • Loading branch information
Dylan-DPC committed Jun 19, 2021
2 parents 488a068 + e4b3131 commit 212f703
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions library/test/src/formatters/junit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ impl<T: Write> OutputFormatter for JunitFormatter<T> {
name=\"{}\" time=\"{}\">",
class_name,
test_name,
duration.as_secs()
duration.as_secs_f64()
))?;
self.write_message("<failure type=\"assert\"/>")?;
self.write_message("</testcase>")?;
Expand All @@ -91,7 +91,7 @@ impl<T: Write> OutputFormatter for JunitFormatter<T> {
name=\"{}\" time=\"{}\">",
class_name,
test_name,
duration.as_secs()
duration.as_secs_f64()
))?;
self.write_message(&*format!("<failure message=\"{}\" type=\"assert\"/>", m))?;
self.write_message("</testcase>")?;
Expand All @@ -103,7 +103,7 @@ impl<T: Write> OutputFormatter for JunitFormatter<T> {
name=\"{}\" time=\"{}\">",
class_name,
test_name,
duration.as_secs()
duration.as_secs_f64()
))?;
self.write_message("<failure type=\"timeout\"/>")?;
self.write_message("</testcase>")?;
Expand All @@ -123,7 +123,7 @@ impl<T: Write> OutputFormatter for JunitFormatter<T> {
name=\"{}\" time=\"{}\"/>",
class_name,
test_name,
duration.as_secs()
duration.as_secs_f64()
))?;
}
}
Expand Down

0 comments on commit 212f703

Please sign in to comment.