Skip to content

Commit 031e27c

Browse files
authored
Merge pull request #301 from magento-gl/ACQE-4951
ACQE-4951 : Handled Exception Serialization of weakMap is not allowed…
2 parents 36a47aa + c4c2bfe commit 031e27c

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/Magento/FunctionalTestingFramework/Allure/AllureHelper.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,11 @@ class AllureHelper
2323
public static function addAttachmentToCurrentStep($data, $caption): void
2424
{
2525
if (!is_string($data)) {
26-
$data = serialize($data);
26+
try {
27+
$data = serialize($data);
28+
} catch (\Exception $exception) {
29+
throw new \Exception($data->getMessage());
30+
}
2731
}
2832
if (@file_exists($data) && is_file($data)) {
2933
Allure::attachmentFile($caption, $data);

0 commit comments

Comments
 (0)