Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,18 @@
"email": "[email protected]"
}],
"require": {
"php": ">=5.5",
"php": ">=7.3",
"mpociot/phpws": "^2.0",
"evenement/evenement": "~3.0",
"guzzlehttp/guzzle": "~6.0",
"guzzlehttp/guzzle": "~6.0|~7.0",
"react/event-loop": "^1.0 || ^0.5 || ^0.4",
"react/promise": "^2.2",
"react/promise-timer": "^1.2.1"
},
"require-dev": {
"phpunit/phpunit": "~4.6",
"fzaninotto/faker": "~1.4",
"apigen/apigen": "^4.1"
"phpunit/phpunit": "~9.4",
"apigen/apigen": "^4.1",
"fakerphp/faker": "^1.13"
},
"autoload": {
"psr-4": {
Expand Down
22 changes: 11 additions & 11 deletions phpunit.xml.dist
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<phpunit bootstrap="vendor/autoload.php" colors="true">
<testsuites>
<testsuite name="slack-client">
<directory>tests</directory>
</testsuite>
</testsuites>
<filter>
<whitelist>
<directory>src</directory>
</whitelist>
</filter>
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" bootstrap="vendor/autoload.php" colors="true" xsi:noNamespaceSchemaLocation="https://schema.phpunit.de/9.3/phpunit.xsd">
<coverage>
<include>
<directory>src</directory>
</include>
</coverage>
<testsuites>
<testsuite name="slack-client">
<directory>tests</directory>
</testsuite>
</testsuites>
</phpunit>
2 changes: 1 addition & 1 deletion tests/Message/MessageBuilderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class MessageBuilderTest extends TestCase
{
protected $builder;

public function setUp()
public function setUp(): void
{
parent::setUp();

Expand Down
7 changes: 4 additions & 3 deletions tests/TestCase.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,15 @@
use GuzzleHttp\HandlerStack;
use GuzzleHttp\Middleware;
use GuzzleHttp\Psr7\Response;
use PHPUnit\Framework\TestCase as BaseTestcase;
use React\EventLoop\Factory;
use React\Promise\ExtendedPromiseInterface;
use Slack\ApiClient;

/**
* Base helper class for test cases for mocking API requests and responses.
*/
abstract class TestCase extends \PHPUnit_Framework_TestCase
abstract class TestCase extends BaseTestcase
{
/**
* @var \Faker\Generator A Faker fake data generator.
Expand Down Expand Up @@ -53,7 +54,7 @@ abstract class TestCase extends \PHPUnit_Framework_TestCase
/**
* Sets up a test with some useful mock objects.
*/
public function setUp()
public function setUp(): void
{
// Create a mock handler
$this->mock = new MockHandler();
Expand Down Expand Up @@ -83,7 +84,7 @@ public function setUp()
/**
* Works in conjunction with watchPromise() to unwrap promise exceptions.
*/
public function tearDown()
public function tearDown(): void
{
$this->loop->run();

Expand Down