Subversion Repositories cheapmusic

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
103 - 1
<?php
2
 
3
namespace Google\Auth\tests;
4
 
5
use GuzzleHttp\ClientInterface;
6
 
7
abstract class BaseTest extends \PHPUnit_Framework_TestCase
8
{
9
    public function onlyGuzzle6()
10
    {
11
        $version = ClientInterface::VERSION;
12
        if ('6' !== $version[0]) {
13
            $this->markTestSkipped('Guzzle 6 only');
14
        }
15
    }
16
 
17
    public function onlyGuzzle5()
18
    {
19
        $version = ClientInterface::VERSION;
20
        if ('5' !== $version[0]) {
21
            $this->markTestSkipped('Guzzle 5 only');
22
        }
23
    }
24
 
25
    /**
26
     * @see Google\Auth\$this->getValidKeyName
27
     */
28
    public function getValidKeyName($key)
29
    {
30
        return preg_replace('|[^a-zA-Z0-9_\.! ]|', '', $key);
31
    }
32
}