Skip to content

Commit

Permalink
Merge pull request #9 from qvers/codeception-5-support
Browse files Browse the repository at this point in the history
Add codeception 5 support
  • Loading branch information
dedpikhto authored May 17, 2023
2 parents 4273e66 + 3674393 commit 2881b41
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 17 deletions.
19 changes: 9 additions & 10 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,17 +24,16 @@
"description" : "Wiremock extension for Codeception",
"license" : "GPL-3.0+",
"require" : {
"php" : ">=5.6",
"codeception/codeception" : "^2.0.0 || ^3.0.0 || ^4.0.0 || ^5.0.0",
"wiremock-php/wiremock-php" : "^2.18"
"php" : ">=8.0",
"codeception/codeception" : "^5.0.0",
"wiremock-php/wiremock-php" : "^2.35.1"
},
"require-dev" : {
"phing/phing" : "^2.12.0",
"squizlabs/php_codesniffer" : "^2.3.4",
"phpmd/phpmd" : "^2.3.2",
"sebastian/phpcpd" : "^2.0.2",
"pdepend/pdepend" : "^2.0.6",
"phploc/phploc" : "^2.1.1",
"phpdocumentor/phpdocumentor" : "^2.8.5"
"phing/phing" : "^2.17.4",
"squizlabs/php_codesniffer" : "^3.7.2",
"phpmd/phpmd" : "^2.13.0",
"pdepend/pdepend" : "^2.13.0",
"codeception/module-phpbrowser": "^3.0",
"codeception/module-asserts": "^3.0"
}
}
2 changes: 1 addition & 1 deletion src/Extension/WireMock.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
*/
namespace Codeception\Extension;

use Codeception\Platform\Extension as CodeceptionExtension;
use Codeception\Extension as CodeceptionExtension;
use WireMock\Client\WireMock as WireMockClient;

/**
Expand Down
2 changes: 1 addition & 1 deletion src/Extension/WireMockArguments.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ class WireMockArguments
*/
public function __construct()
{
$this->defaults['logs-path'] = Config::logDir();
$this->defaults['logs-path'] = Config::outputDir();
}

/**
Expand Down
4 changes: 2 additions & 2 deletions src/Module/WireMock.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class WireMock extends CodeceptionModule
*/
private $wireMock;

protected $config = [
protected array $config = [
'host' => 'localhost',
'port' => '8080'
];
Expand All @@ -39,7 +39,7 @@ class WireMock extends CodeceptionModule
* {@inheritDoc}
* @see \Codeception\Module::_beforeSuite()
*/
public function _beforeSuite($settings = [])
public function _beforeSuite(array $settings = [])
{
$this->config = array_merge($this->config, $settings);
Debug::debug(
Expand Down
1 change: 1 addition & 0 deletions tests/codeception.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ paths:
data: tests/_data
support: tests/_support
envs: tests/_envs
output: tests/_output
settings:
bootstrap: _bootstrap.php
colors: true
Expand Down
2 changes: 1 addition & 1 deletion tests/tests/acceptance.suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Perform tests in browser using the WebDriver or PhpBrowser.
# If you need both WebDriver and PHPBrowser tests - create a separate suite.

class_name: AcceptanceTester
actor: AcceptanceTester
modules:
enabled:
- PhpBrowser
Expand Down
2 changes: 1 addition & 1 deletion tests/tests/functional.suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# Emulate web requests and make application process them
# Include one of framework modules (Symfony2, Yii2, Laravel5) to use it

class_name: FunctionalTester
actor: FunctionalTester
modules:
enabled:
# add framework module here
Expand Down
2 changes: 1 addition & 1 deletion tests/tests/unit.suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#
# Suite for unit (internal) tests.

class_name: UnitTester
actor: UnitTester
modules:
enabled:
- Asserts
Expand Down

0 comments on commit 2881b41

Please sign in to comment.