Ejemplo n.º 1
0
 /**
  * Method to test isLinux().
  *
  * @param string  $os
  * @param boolean $value
  *
  * @return void
  *
  * @dataProvider getIsLinuxTestData
  *
  * @covers Windwalker\Application\Environment\Server::isLinux
  */
 public function testIsLinux($os, $value)
 {
     $this->instance->setOS(null);
     $this->instance->setUname($os);
     $this->assertEquals($value, $this->instance->isLinux());
 }
Ejemplo n.º 2
0
<?php

/**
 * Part of Windwalker project. 
 *
 * @copyright  Copyright (C) 2014 {ORGANIZATION}. All rights reserved.
 * @license    GNU Lesser General Public License version 2.1 or later.
 */
use Windwalker\Environment\Server;
$autoload = __DIR__ . '/../../../vendor/autoload.php';
if (!is_file($autoload)) {
    $autoload = __DIR__ . '/../vendor/autoload.php';
}
include_once $autoload;
$server = new Server();
echo $server->getEntry();
echo "\n";
echo $server->getWorkingDirectory();
echo "\n\n";