From c8e0492e067044b40c26999ddaf0ac70a44c571e Mon Sep 17 00:00:00 2001 From: Andrei Usov Date: Mon, 2 May 2022 11:55:42 +0300 Subject: [PATCH] Fix files attaching (issue https://help.qameta.io/support/tickets/297) --- src/Internal/TestLifecycle.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Internal/TestLifecycle.php b/src/Internal/TestLifecycle.php index 7ee466c..37c0669 100644 --- a/src/Internal/TestLifecycle.php +++ b/src/Internal/TestLifecycle.php @@ -239,7 +239,7 @@ public function attachReports(): self if (!is_string($artifact)) { continue; } - $dataSource = @file_exists($artifact) && !is_file($artifact) + $dataSource = @file_exists($artifact) && is_file($artifact) ? DataSourceFactory::fromFile($artifact) : DataSourceFactory::fromString($artifact); $this