phpunit
This commit is contained in:
17
test.php
Normal file
17
test.php
Normal file
@ -0,0 +1,17 @@
|
||||
<?php
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class IndexTest extends TestCase
|
||||
{
|
||||
public function testHello(): void
|
||||
{
|
||||
$_GET['name'] = 'Poopiebutt';
|
||||
|
||||
ob_start();
|
||||
include 'index.php';
|
||||
$content = ob_get_clean();
|
||||
|
||||
$this->assertEquals('Hello Poopiebutt', $content);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user