Skip to content

Commit

Permalink
Test enhancement
Browse files Browse the repository at this point in the history
  • Loading branch information
peter279k authored and Kevinrob committed Jan 9, 2020
1 parent 3a1bb0c commit 8f18549
Show file tree
Hide file tree
Showing 16 changed files with 39 additions and 25 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ php:
- 7.1
- 7.2
- 7.3
- 7.4
- nightly

matrix:
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"php": ">=5.5.0"
},
"require-dev": {
"phpunit/phpunit": "^4.0 || ^5.0",
"phpunit/phpunit": "^4.8.36 || ^5.0",
"guzzlehttp/guzzle": "^6.0",
"doctrine/cache": "^1.0",
"league/flysystem": "^1.0",
Expand Down
5 changes: 3 additions & 2 deletions tests/BaseTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,16 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class BaseTest extends \PHPUnit_Framework_TestCase
class BaseTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
2 changes: 1 addition & 1 deletion tests/DelegatingCacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class DelegatingCacheTest extends TestCase
*/
protected $stack;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$this->stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
3 changes: 2 additions & 1 deletion tests/GreedyCacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,9 @@
use Kevinrob\GuzzleCache\KeyValueHttpHeader;
use Kevinrob\GuzzleCache\Strategy\GreedyCacheStrategy;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class GreedyCacheTest extends \PHPUnit_Framework_TestCase
class GreedyCacheTest extends TestCase
{
/**
* @var Client
Expand Down
5 changes: 3 additions & 2 deletions tests/HeaderExpireTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,15 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

/**
* Created by IntelliJ IDEA.
* User: Kevin
* Date: 29.06.2015
* Time: 22:48.
*/
class HeaderExpireTest extends \PHPUnit_Framework_TestCase
class HeaderExpireTest extends TestCase
{
/**
* @var Client
Expand All @@ -27,7 +28,7 @@ class HeaderExpireTest extends \PHPUnit_Framework_TestCase
*/
protected $sendError = false;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/InvalidateCacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,16 @@
use GuzzleHttp\Promise\FulfilledPromise;
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use PHPUnit\Framework\TestCase;

class InvalidateCacheTest extends \PHPUnit_Framework_TestCase
class InvalidateCacheTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function () {
Expand Down
3 changes: 2 additions & 1 deletion tests/KeyValueHttpHeaderTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,9 @@

use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\KeyValueHttpHeader;
use PHPUnit\Framework\TestCase;

class KeyValueHttpHeaderTest extends \PHPUnit_Framework_TestCase
class KeyValueHttpHeaderTest extends TestCase
{
public function testBase()
{
Expand Down
3 changes: 2 additions & 1 deletion tests/PrivateCacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,9 @@
use Kevinrob\GuzzleCache\Storage\VolatileRuntimeStorage;
use Kevinrob\GuzzleCache\Strategy\PrivateCacheStrategy;
use League\Flysystem\Adapter\Local;
use PHPUnit\Framework\TestCase;

class PrivateCacheTest extends \PHPUnit_Framework_TestCase
class PrivateCacheTest extends TestCase
{
public function testCacheProvider()
{
Expand Down
5 changes: 3 additions & 2 deletions tests/PublicCacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,16 @@
use Kevinrob\GuzzleCache\Strategy\PublicCacheStrategy;
use League\Flysystem\Adapter\Local;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class PublicCacheTest extends \PHPUnit_Framework_TestCase
class PublicCacheTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/RequestCacheControlTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class RequestCacheControlTest extends \PHPUnit_Framework_TestCase
class RequestCacheControlTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/ResponseAgeTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class ResponseAgeTest extends \PHPUnit_Framework_TestCase
class ResponseAgeTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/ResponseCacheControlTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class ResponseCacheControlTest extends \PHPUnit_Framework_TestCase
class ResponseCacheControlTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/ResponseVaryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,16 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class ResponseVaryTest extends \PHPUnit_Framework_TestCase
class ResponseVaryTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/Strategy/GreedyCacheStrategyTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,16 @@
use Kevinrob\GuzzleCache\CacheMiddleware;
use Kevinrob\GuzzleCache\Storage\VolatileRuntimeStorage;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

class GreedyCacheStrategyTest extends \PHPUnit_Framework_TestCase
class GreedyCacheStrategyTest extends TestCase
{
/**
* @var Client
*/
protected $client;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down
5 changes: 3 additions & 2 deletions tests/ValidationTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,15 @@
use GuzzleHttp\Psr7\Response;
use Kevinrob\GuzzleCache\CacheMiddleware;
use Psr\Http\Message\RequestInterface;
use PHPUnit\Framework\TestCase;

/**
* Created by IntelliJ IDEA.
* User: Kevin
* Date: 30.06.2015
* Time: 12:58.
*/
class ValidationTest extends \PHPUnit_Framework_TestCase
class ValidationTest extends TestCase
{
/**
* @var Client
Expand All @@ -27,7 +28,7 @@ class ValidationTest extends \PHPUnit_Framework_TestCase
*/
protected $cache;

public function setUp()
protected function setUp()
{
// Create default HandlerStack
$stack = HandlerStack::create(function (RequestInterface $request, array $options) {
Expand Down

0 comments on commit 8f18549

Please sign in to comment.