Вход Регистрация
Файл: gapps/vendor/sebastian/environment/tests/RuntimeTest.php
Строк: 277
<?php
/*
 * This file is part of the Environment package.
 *
 * (c) Sebastian Bergmann <sebastian@phpunit.de>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace SebastianBergmannEnvironment;

use 
PHPUnit_Framework_TestCase;

class 
RuntimeTest extends PHPUnit_Framework_TestCase
{
    
/**
     * @var SebastianBergmannEnvironmentRuntime
     */
    
private $env;

    protected function 
setUp()
    {
        
$this->env = new Runtime;
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::canCollectCodeCoverage
     * @uses   SebastianBergmannEnvironmentRuntime::hasXdebug
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     * @uses   SebastianBergmannEnvironmentRuntime::isPHP
     */
    
public function testAbilityToCollectCodeCoverageCanBeAssessed()
    {
        
$this->assertInternalType('boolean'$this->env->canCollectCodeCoverage());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::getBinary
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testBinaryCanBeRetrieved()
    {
        
$this->assertInternalType('string'$this->env->getBinary());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testCanBeDetected()
    {
        
$this->assertInternalType('boolean'$this->env->isHHVM());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::isPHP
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testCanBeDetected2()
    {
        
$this->assertInternalType('boolean'$this->env->isPHP());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::hasXdebug
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     * @uses   SebastianBergmannEnvironmentRuntime::isPHP
     */
    
public function testXdebugCanBeDetected()
    {
        
$this->assertInternalType('boolean'$this->env->hasXdebug());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::getNameWithVersion
     * @uses   SebastianBergmannEnvironmentRuntime::getName
     * @uses   SebastianBergmannEnvironmentRuntime::getVersion
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     * @uses   SebastianBergmannEnvironmentRuntime::isPHP
     */
    
public function testNameAndVersionCanBeRetrieved()
    {
        
$this->assertInternalType('string'$this->env->getNameWithVersion());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::getName
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testNameCanBeRetrieved()
    {
        
$this->assertInternalType('string'$this->env->getName());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::getVersion
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testVersionCanBeRetrieved()
    {
        
$this->assertInternalType('string'$this->env->getVersion());
    }

    
/**
     * @covers SebastianBergmannEnvironmentRuntime::getVendorUrl
     * @uses   SebastianBergmannEnvironmentRuntime::isHHVM
     */
    
public function testVendorUrlCanBeRetrieved()
    {
        
$this->assertInternalType('string'$this->env->getVendorUrl());
    }
}
Онлайн: 0
Реклама