-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactor and begin to fix tests - add unit testcase for Nullable Retu…
…rn Type (see GH-273)
- Loading branch information
Showing
3 changed files
with
64 additions
and
23 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
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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?php declare(strict_types=1); | ||
|
||
namespace Bartlett\Tests\CompatInfo\Sniffs; | ||
|
||
use Bartlett\CompatInfo\Analyser\CompatibilityAnalyser; | ||
use Bartlett\CompatInfo\Client; | ||
|
||
abstract class SniffTestCase extends \PHPUnit\Framework\TestCase | ||
{ | ||
protected static $fixtures; | ||
protected static $analyserId; | ||
protected static $api; | ||
|
||
/** | ||
* Sets up the shared fixture. | ||
* | ||
* @return void | ||
*/ | ||
public static function setUpBeforeClass(): void | ||
{ | ||
self::$fixtures = dirname(__DIR__) . DIRECTORY_SEPARATOR | ||
. 'fixtures' . DIRECTORY_SEPARATOR | ||
. 'sniffs' . DIRECTORY_SEPARATOR | ||
; | ||
|
||
self::$analyserId = CompatibilityAnalyser::class; | ||
|
||
$client = new Client(); | ||
|
||
// request for a Bartlett\CompatInfo\Api\Analyser | ||
self::$api = $client->api('analyser'); | ||
} | ||
} |
File renamed without changes.