File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
src/Magento/FunctionalTestingFramework/Allure/Adapter Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -104,10 +104,13 @@ private function sanitizeGroupName($group)
104104 }
105105
106106 /**
107- * Override of parent method, only different to prevent replacing of . to •
107+ * Override of parent method:
108+ * prevent replacing of . to •
109+ * strips control characters
108110 *
109111 * @param StepEvent $stepEvent
110112 * @return void
113+ * @throws \Yandex\Allure\Adapter\AllureException
111114 */
112115 public function stepBefore (StepEvent $ stepEvent )
113116 {
@@ -129,6 +132,9 @@ public function stepBefore(StepEvent $stepEvent)
129132
130133 $ stepName = $ stepAction . ' ' . $ stepArgs ;
131134
135+ // Strip control characters so that report generation does not fail
136+ $ stepName = preg_replace ('/[[:cntrl:]]/ ' , '' , $ stepName );
137+
132138 $ this ->emptyStep = false ;
133139 $ this ->getLifecycle ()->fire (new StepStartedEvent ($ stepName ));
134140 }
You can’t perform that action at this time.
0 commit comments