Tests
This commit is contained in:
22
app/tests/acceptance/HomeTest.php
Normal file
22
app/tests/acceptance/HomeTest.php
Normal file
@ -0,0 +1,22 @@
|
||||
<?php
|
||||
use PHPUnit\Framework;
|
||||
|
||||
class HomeTest extends Framework\TestCase
|
||||
{
|
||||
public function testLoadHome(): void
|
||||
{
|
||||
$client = new GuzzleHttp\Client(['base_uri' => 'http://proxy']);
|
||||
$home = $client->get('');
|
||||
$home = $home->getBody()->getContents();
|
||||
|
||||
$expected = [
|
||||
'<!DOCTYPE html>',
|
||||
'<title>Incoviba</title>',
|
||||
'<img src="http://localhost:8080/assets/images/logo_cabezal.png" alt="logo" />',
|
||||
'Bienvenid@ a Incoviba'
|
||||
];
|
||||
foreach ($expected as $segment) {
|
||||
$this->assertStringContainsString($segment, $home);
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user