31 lines
873 B
PHP
31 lines
873 B
PHP
<?php
|
|
|
|
namespace Tests\Feature;
|
|
|
|
use Illuminate\Foundation\Testing\DatabaseTransactions;
|
|
use Inertia\Testing\AssertableInertia as Assert;
|
|
use Tests\Support\ProactiveInvestmentFixture;
|
|
use Tests\TestCase;
|
|
|
|
final class FiscalFormEntryTest extends TestCase
|
|
{
|
|
use DatabaseTransactions;
|
|
|
|
protected function setUp(): void
|
|
{
|
|
parent::setUp();
|
|
ProactiveInvestmentFixture::guard();
|
|
$this->withoutVite();
|
|
}
|
|
|
|
public function test_both_fiscal_forms_are_public_and_do_not_redirect_to_legal_documents(): void
|
|
{
|
|
config(['portal.homologation_only' => false]);
|
|
foreach (['iva', 'irpc'] as $tax) {
|
|
$this->get('/formularios/fiscais?imposto='.$tax)
|
|
->assertOk()
|
|
->assertInertia(fn (Assert $page) => $page->component('portal/fiscal-forms')->where('initialTax', $tax));
|
|
}
|
|
}
|
|
}
|