ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
RunTimeTest.php
Go to the documentation of this file.
1<?php
2
19declare(strict_types=1);
20
21use PHPUnit\Framework\TestCase;
22
23class RunTimeTest extends TestCase
24{
25 private function markTestSkippedWhenNoRunningOnPhp(): void
26 {
27 if (!defined('HHVM_VERSION')) {
28 return;
29 }
30
31 $this->markTestSkipped('Cannot run on HHVM');
32 }
33
35 {
37
38 $this->assertSame(PHP_VERSION, ilRuntime::getInstance()->getVersion());
39 }
40
42 {
44
45 $this->assertSame('PHP', ilRuntime::getInstance()->getName());
46 }
47
48 public function testBinaryCanBeRetrieved(): void
49 {
50 $this->assertNotEmpty(ilRuntime::getInstance()->getBinary());
51 }
52}
markTestSkippedWhenNoRunningOnPhp()
Definition: RunTimeTest.php:25
testGetNameReturnsPhpWhenRunningOnPhp()
Definition: RunTimeTest.php:41
testBinaryCanBeRetrieved()
Definition: RunTimeTest.php:48
testGetVersionReturnsPhpVersionWhenRunningPhp()
Definition: RunTimeTest.php:34
static getInstance()