File tree Expand file tree Collapse file tree 6 files changed +40
-4
lines changed
Expand file tree Collapse file tree 6 files changed +40
-4
lines changed Original file line number Diff line number Diff line change 1+ <component name =" ProjectRunConfigurationManager" >
2+ <configuration default =" false" name =" Acceptance" type =" PHPUnitRunConfigurationType" factoryName =" PHPUnit" >
3+ <TestRunner bootstrap_file =" $PROJECT_DIR$/tests/bootstrap.php" configuration_file =" $PROJECT_DIR$/phpunit.xml.dist" directory =" $PROJECT_DIR$/tests/Acceptance" scope =" XML" options =" --testsuite=Acceptance" />
4+ <method v =" 2" />
5+ </configuration >
6+ </component >
Original file line number Diff line number Diff line change 1+ <component name =" ProjectRunConfigurationManager" >
2+ <configuration default =" false" name =" Functional" type =" PHPUnitRunConfigurationType" factoryName =" PHPUnit" >
3+ <TestRunner bootstrap_file =" $PROJECT_DIR$/tests/bootstrap.php" configuration_file =" $PROJECT_DIR$/phpunit.xml.dist" directory =" $PROJECT_DIR$/tests/Functional" scope =" XML" options =" --testsuite=Functional" />
4+ <method v =" 2" />
5+ </configuration >
6+ </component >
Original file line number Diff line number Diff line change 1+ <component name =" ProjectRunConfigurationManager" >
2+ <configuration default =" false" name =" Unit" type =" PHPUnitRunConfigurationType" factoryName =" PHPUnit" >
3+ <TestRunner bootstrap_file =" $PROJECT_DIR$/tests/bootstrap.php" configuration_file =" $PROJECT_DIR$/phpunit.xml.dist" directory =" $PROJECT_DIR$/tests/Functional" scope =" XML" options =" --testsuite=Unit" />
4+ <method v =" 2" />
5+ </configuration >
6+ </component >
Original file line number Diff line number Diff line change 6262 override (\Temporal \Client \WorkflowClient::newRunningWorkflowStub (), map ([
6363 '' => type (0 ),
6464 ]));
65+
66+ override (\Temporal \Client \WorkflowStubInterface::getResult (), map ([
67+ '' => '@ ' ,
68+ ]));
6569}
Original file line number Diff line number Diff line change 7474 <collection name =" temporal/sdk:activity-class" argument =" 0" />
7575 <stopCompletion />
7676 </classMethod >
77+ <classMethod
78+ class =" \Temporal\Workflow\WorkflowRunInterface"
79+ method =" getResult"
80+ argument =" 0" >
81+ <languageInjection language =" InjectablePHP" prefix =" /** @var " suffix =" $_ **/" />
82+ </classMethod >
7783 </definitions >
7884</meta-storm >
Original file line number Diff line number Diff line change @@ -101,14 +101,18 @@ public function startTemporalServer(
101101 );
102102 $ this ->temporalServerProcess ->setTimeout ($ commandTimeout );
103103 $ this ->temporalServerProcess ->start ();
104- $ this ->output ->writeln ('<info>done.</info> ' );
105- \sleep (1 );
104+
105+ $ limit = 1_000_000 ;
106+ while (!$ this ->temporalServerProcess ->isRunning () && $ limit > 0 ) {
107+ \usleep ($ limit -= 1000 );
108+ }
106109
107110 if (!$ this ->temporalServerProcess ->isRunning ()) {
108111 $ this ->output ->writeln ('<error>error</error> ' );
109112 $ this ->output ->writeln ('Error starting Temporal server: ' . $ this ->temporalServerProcess ->getErrorOutput ());
110113 exit (1 );
111114 }
115+ $ this ->output ->writeln ('<info>done.</info> ' );
112116 }
113117
114118 public function startTemporalTestServer (int $ commandTimeout = 10 ): void
@@ -127,14 +131,18 @@ public function startTemporalTestServer(int $commandTimeout = 10): void
127131 );
128132 $ this ->temporalTestServerProcess ->setTimeout ($ commandTimeout );
129133 $ this ->temporalTestServerProcess ->start ();
130- $ this ->output ->writeln ('<info>done.</info> ' );
131- \sleep (1 );
134+
135+ $ limit = 1_000_000 ;
136+ while (!$ this ->temporalTestServerProcess ->isRunning () && $ limit > 0 ) {
137+ \usleep ($ limit -= 1000 );
138+ }
132139
133140 if (!$ this ->temporalTestServerProcess ->isRunning ()) {
134141 $ this ->output ->writeln ('<error>error</error> ' );
135142 $ this ->output ->writeln ('Error starting Temporal Test server: ' . $ this ->temporalTestServerProcess ->getErrorOutput ());
136143 exit (1 );
137144 }
145+ $ this ->output ->writeln ('<info>done.</info> ' );
138146 }
139147
140148 /**
You can’t perform that action at this time.
0 commit comments