Skip to content

Commit

Permalink
upgrades phpunit
Browse files Browse the repository at this point in the history
  • Loading branch information
Pierre Dedy committed Nov 14, 2019
1 parent 915ab5e commit d1edab3
Show file tree
Hide file tree
Showing 24 changed files with 83 additions and 35 deletions.
4 changes: 3 additions & 1 deletion tests/unit-large/BackendTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @license WTFPL
* @author Markus Malkusch <[email protected]>
*/
class BackendTest extends \PHPUnit_Framework_TestCase
class BackendTest extends TestCase
{

/**
Expand Down
6 changes: 4 additions & 2 deletions tests/unit-large/CrossProjectTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -18,7 +20,7 @@
* @license WTFPL
* @large
*/
class CrossProjectTest extends \PHPUnit_Framework_TestCase
class CrossProjectTest extends TestCase
{

/**
Expand Down Expand Up @@ -67,7 +69,7 @@ class CrossProjectTest extends \PHPUnit_Framework_TestCase
*/
private static $testAPIs = array();

public static function setUpBeforeClass()
public static function setUpBeforeClass(): void
{
self::$testAPIs = array(new BAVTestAPI());

Expand Down
10 changes: 6 additions & 4 deletions tests/unit/00UpdatePlanTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -14,7 +16,7 @@
* @license WTFPL
* @author Markus Malkusch <[email protected]>
*/
class UpdatePlanTest extends \PHPUnit_Framework_TestCase
class UpdatePlanTest extends TestCase
{

/**
Expand Down Expand Up @@ -65,7 +67,7 @@ public function testIsOutdated($mtime, $time, $expectedIsOutdated)
}

/**
* @expectedException \PHPUnit_Framework_Error_Warning
* @expectedException \PHPUnit\Framework\Error\Warning
*/
public function testLogUpdatePlan()
{
Expand All @@ -74,7 +76,7 @@ public function testLogUpdatePlan()
}

/**
* @expectedException \PHPUnit_Framework_Error_Notice
* @expectedException \PHPUnit\Framework\Error\Notice
* @medium
*/
public function testAutomaticUpdatePlanNotice()
Expand All @@ -86,7 +88,7 @@ public function testAutomaticUpdatePlanNotice()
}

/**
* @expectedException \PHPUnit_Framework_Error_Notice
* @expectedException \PHPUnit\Framework\Error\Notice
* @medium
*/
public function testAutomaticUpdatePlan()
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/AgencyQueryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -10,7 +12,7 @@
* @author Markus Malkusch <[email protected]>
* @licends GPL
*/
class AgencyQueryTest extends \PHPUnit_Framework_TestCase
class AgencyQueryTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/BAVFacadeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @author Markus Malkusch <[email protected]>
* @see BAV
*/
class BAVFacadeTest extends \PHPUnit_Framework_TestCase
class BAVFacadeTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/BICUtilTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @see BICUtil
* @author Markus Malkusch <[email protected]>
*/
class BICUtilTest extends \PHPUnit_Framework_TestCase
class BICUtilTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/BackendContainerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -10,7 +12,7 @@
* @license WTFPL
* @author Markus Malkusch <[email protected]>
*/
class BackendContainerTest extends \PHPUnit_Framework_TestCase
class BackendContainerTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/ConfigurationLocatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @licends GPL
* @see ConfigurationLocator
*/
class ConfigurationLocatorTest extends \PHPUnit_Framework_TestCase
class ConfigurationLocatorTest extends TestCase
{

/**
Expand Down
6 changes: 4 additions & 2 deletions tests/unit/ConfigurationRegistryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,13 +13,13 @@
* @licends GPL
* @see ConfigurationRegistry
*/
class ConfigurationRegistryTest extends \PHPUnit_Framework_TestCase
class ConfigurationRegistryTest extends TestCase
{

/**
* Disable update hook
*/
protected function tearDown()
protected function tearDown(): void
{
ConfigurationRegistry::getConfiguration()->setUpdatePlan(null);
}
Expand Down
6 changes: 4 additions & 2 deletions tests/unit/ContextValidationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,15 +13,15 @@
* @see ContextValidation
* @author Markus Malkusch <[email protected]>
*/
class ContextValidationTest extends \PHPUnit_Framework_TestCase
class ContextValidationTest extends TestCase
{

/**
* @var ContextValidation
*/
private $validation;

protected function setUp()
protected function setUp(): void
{
$bav = new BAV();
$this->validation = new ContextValidation($bav->getDataBackend());
Expand Down
6 changes: 4 additions & 2 deletions tests/unit/DataConstraintTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,20 +2,22 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
* Test if the banklist.txt fits into the model.
*/
class DataConstraintTest extends \PHPUnit_Framework_TestCase
class DataConstraintTest extends TestCase
{

/**
* @var \PDO
*/
private static $pdo;

public static function setUpBeforeClass()
public static function setUpBeforeClass(): void
{

self::$pdo = PDOFactory::makePDO();
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/DownloaderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -10,7 +12,7 @@
* @license WTFPL
* @author Markus Malkusch <[email protected]>
*/
class DownloaderTest extends \PHPUnit_Framework_TestCase
class DownloaderTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/FileParserTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -12,7 +14,7 @@
* @link bitcoin:1335STSwu9hST4vcMRppEPgENMHD2r1REK Donations
* @see FileParser
*/
class FileParserTest extends \PHPUnit_Framework_TestCase
class FileParserTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/FileUtilTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @author Markus Malkusch <[email protected]>
* @license WTFPL
*/
class FileUtilTest extends \PHPUnit_Framework_TestCase
class FileUtilTest extends TestCase
{

/**
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/FileValidatorTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @author Markus Malkusch <[email protected]>
* @see BAV
*/
class FileValidatorTest extends \PHPUnit_Framework_TestCase
class FileValidatorTest extends TestCase
{

public function testValidate()
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/LockTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,7 +13,7 @@
* @author Markus Malkusch <[email protected]>
* @see Lock
*/
class LockTest extends \PHPUnit_Framework_TestCase
class LockTest extends TestCase
{

/**
Expand Down
6 changes: 4 additions & 2 deletions tests/unit/StatementContainerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -11,15 +13,15 @@
* @author Markus Malkusch <[email protected]>
* @see StatementContainer
*/
class StatementContainerTest extends \PHPUnit_Framework_TestCase
class StatementContainerTest extends TestCase
{

/**
* @var StatementContainer
*/
private $statementContainer;

public function setUp()
public function setUp(): void
{
$this->statementContainer = new StatementContainer(PDOFactory::makePDO());
}
Expand Down
4 changes: 3 additions & 1 deletion tests/unit/URIPickerTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

namespace malkusch\bav;

use PHPUnit\Framework\TestCase;

require_once __DIR__ . "/../bootstrap.php";

/**
Expand All @@ -10,7 +12,7 @@
* @license WTFPL
* @author Markus Malkusch <[email protected]>
*/
class URIPickerTest extends \PHPUnit_Framework_TestCase
class URIPickerTest extends TestCase
{

/**
Expand Down
Loading

0 comments on commit d1edab3

Please sign in to comment.