GildedRose-Refactoring-Kata/php/tests/ApprovalTest.php
Pen-y-Fan ed7a787e4f Updated PHP version for PHP7.2+
Removed PHP5 (no longer supported)
Renamed PHP7 to PHP - consistent with other kata
Added the same helpers as other PHP Kata
Updated the code to PHP7.2+ standard
Didn't change GildedRose updateQuality method
Updated GildedRoseTest (still failing)
Added ApprovalTest (passing)
- same text file as texttests / ThirtyDays / stdout.gr (only renamed).
2020-07-23 22:47:36 +01:00

25 lines
468 B
PHP

<?php
declare(strict_types=1);
namespace Tests;
use ApprovalTests\Approvals;
use PHPUnit\Framework\TestCase;
class ApprovalTest extends TestCase
{
public function testTestFixture(): void
{
$argv[0] = 'texttest_fixture.php';
$argv[1] = 31;
ob_start();
require_once __DIR__ . '/../fixtures/texttest_fixture.php';
$output = ob_get_contents();
ob_end_clean();
Approvals::verifyString($output);
}
}