Skip to content

Commit 20ed813

Browse files
Add setScenarioState to module (#38)
* Add setScenarioState to module * Remove type hints
1 parent 56f5f9e commit 20ed813

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

src/Module/Phiremock.php

+11
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
use Mcustiel\Phiremock\Client\Phiremock as PhiremockClient;
2626
use Mcustiel\Phiremock\Client\Utils\RequestBuilder;
2727
use Mcustiel\Phiremock\Domain\Expectation;
28+
use Mcustiel\Phiremock\Domain\ScenarioState;
2829

2930
class Phiremock extends CodeceptionModule
3031
{
@@ -122,4 +123,14 @@ public function grabRequestsMadeToRemoteService(RequestBuilder $builder)
122123
{
123124
return $this->phiremock->listExecutions($builder);
124125
}
126+
127+
/**
128+
* @param string $name
129+
* @param string $state
130+
*/
131+
public function setScenarioState($name, $state)
132+
{
133+
$scenarioState = new ScenarioState($name, $state);
134+
$this->phiremock->setScenarioState($scenarioState);
135+
}
125136
}

0 commit comments

Comments
 (0)