-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
49 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
language: php | ||
|
||
php: | ||
- 7.0 | ||
- 7.1 | ||
- 7.3 | ||
- 7.4 | ||
- 8.0 | ||
|
||
before_script: | ||
- travis_retry composer self-update | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,27 @@ | ||
<?php | ||
|
||
use Vinelab\Minion\Minion; | ||
use Vinelab\Minion\InvalidProviderException; | ||
|
||
/** | ||
* @author Abed Halawi <[email protected]> | ||
*/ | ||
class MinionTest extends PHPUnit\Framework\TestCase | ||
{ | ||
public function setUp() | ||
public function setUp(): void | ||
{ | ||
$this->m = new Minion(); | ||
} | ||
|
||
/** | ||
* @expectedException Vinelab\Minion\InvalidProviderException | ||
* @expectedExceptionMessage Provider NonProvider must be an instance of \Vinelab\Minion\Provider | ||
*/ | ||
public function test_registering_non_provider_fails() | ||
public function test_registering_non_provider_fails(): void | ||
{ | ||
$this->expectException(InvalidProviderException::class); | ||
$this->expectExceptionMessage('Provider NonProvider must be an instance of \Vinelab\Minion\Provider'); | ||
|
||
$this->m->register('NonProvider'); | ||
} | ||
|
||
public function test_does_not_register_duplicates() | ||
public function test_does_not_register_duplicates(): void | ||
{ | ||
$this->m->register('AProvider'); | ||
$this->m->register('AProvider'); | ||
|
@@ -43,12 +43,12 @@ public function test_default_config() | |
$this->assertEquals($default, $this->m->getConfig()); | ||
} | ||
|
||
public function test_getting_config_param() | ||
public function test_getting_config_param(): void | ||
{ | ||
$this->assertEquals('minion', $this->m->getConfig('realm')); | ||
} | ||
|
||
public function test_merging_config() | ||
public function test_merging_config(): void | ||
{ | ||
$options = [ | ||
'realm' => 'secrets', | ||
|
@@ -60,14 +60,14 @@ public function test_merging_config() | |
$this->assertEquals($merged, $this->m->getConfig()); | ||
} | ||
|
||
public function test_config_tls() | ||
public function test_config_tls(): void | ||
{ | ||
$this->assertEquals(false, $this->m->getConfig('tls')); | ||
$this->m->mergeConfig(['tls'=>true]); | ||
$this->assertEquals(true, $this->m->getConfig('tls')); | ||
} | ||
|
||
public function test_config_path() | ||
public function test_config_path(): void | ||
{ | ||
$path = '/websocket'; | ||
$this->assertEquals('/ws', $this->m->getConfig('path')); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters