From 2e2a59fe4151054d3c1b507bfd01b45e2a46b2bd Mon Sep 17 00:00:00 2001 From: Egor Larichev Date: Tue, 23 Oct 2018 17:12:25 +0300 Subject: [PATCH] fix error "results.elapsed is not in a valid time span format" when elapsed value is less then 1 --- src/Extension.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Extension.php b/src/Extension.php index 456f304..b842ae3 100644 --- a/src/Extension.php +++ b/src/Extension.php @@ -369,9 +369,9 @@ public function getCaseForTest(TestInterface $test) */ public function formatTime($time) { - // TestRail doesn't support subsecond times + // In TestRail version 5.5 was added support of milliseconds if ($time < 1.0) { - return '0s'; + return round($time, 2) .'s'; } $formatted = '';