@@ -898,7 +898,12 @@ public function generateStepsPhp($actionObjects, $generationScope = TestGenerato
898898 $ stepKey
899899 $ customActionAttributes'class ' ] . ':: '  . $ customActionAttributes'method ' ]
900900 );
901-  $ testSteps$ this wrapFunctionCall ($ actor$ actionObject$ arguments
901+  $ testSteps$ this wrapFunctionCallWithReturnValue (
902+  $ stepKey
903+  $ actor
904+  $ actionObject
905+  $ arguments
906+  );
902907 break ;
903908 case  "createData " :
904909 $ entity$ customActionAttributes'entity ' ];
@@ -2016,16 +2021,7 @@ private function addDollarSign($input)
20162021 */ 
20172022 private  function  wrapFunctionCall ($ actor$ action$ args
20182023 {
2019-  $ isFirsttrue ;
2020-  $ isActionHelper$ actiongetType () === 'helper ' ;
2021-  $ actionType$ actiongetType ();
2022-  if  ($ isActionHelper
2023-  $ actor"this->helperContainer->get(' "  . $ actiongetCustomActionAttributes ()['class ' ] . "') " ;
2024-  $ args$ args0 ];
2025-  $ actionType$ actiongetCustomActionAttributes ()['method ' ];
2026-  }
2027- 
2028-  $ outputsprintf ("\t\t$%s->%s( " , $ actor$ actionType
2024+  $ outputsprintf ("\t\t$%s->%s( " , $ actor$ actiongetType ());
20292025 for  ($ i0 ; $ icount ($ args$ i
20302026 if  (null  === $ args$ i
20312027 continue ;
@@ -2046,17 +2042,22 @@ private function wrapFunctionCall($actor, $action, ...$args)
20462042 /** 
20472043 * Wrap parameters into a function call with a return value. 
20482044 * 
2049-  * @param string $returnVariable 
2050-  * @param string $actor 
2051-  * @param string  $action 
2052-  * @param array ...$args 
2045+  * @param string   $returnVariable 
2046+  * @param string   $actor 
2047+  * @param actionObject  $action 
2048+  * @param array   ...$args 
20532049 * @return string 
20542050 * @throws \Exception 
20552051 */ 
20562052 private  function  wrapFunctionCallWithReturnValue ($ returnVariable$ actor$ action$ args
20572053 {
2058-  $ isFirsttrue ;
2059-  $ outputsprintf ("\t\t$%s = $%s->%s( " , $ returnVariable$ actor$ actiongetType ());
2054+  $ actionType$ actiongetType ();
2055+  if  ($ actionType'helper ' ) {
2056+  $ actor"this->helperContainer->get(' "  . $ actiongetCustomActionAttributes ()['class ' ] . "') " ;
2057+  $ args$ args0 ];
2058+  $ actionType$ actiongetCustomActionAttributes ()['method ' ];
2059+  }
2060+  $ outputsprintf ("\t\t$%s = $%s->%s( " , $ returnVariable$ actor$ actionType
20602061 for  ($ i0 ; $ icount ($ args$ i
20612062 if  (null  === $ args$ i
20622063 continue ;
0 commit comments