This commit is contained in:
@@ -82,6 +82,19 @@ class ExistingBusinessWizardTest extends TestCase
|
||||
$this->assertStringNotContainsString('synthetic@example.test', $raw);
|
||||
}
|
||||
|
||||
public function test_company_purchase_is_a_distinct_existing_business_modality(): void
|
||||
{
|
||||
config(['existing-business.enabled' => true]);
|
||||
$owner = User::factory()->create();
|
||||
$this->actingAs($owner)->postJson('/api/v1/existing-business/listings', [
|
||||
'modality' => 'company_purchase', 'classification' => 'confidential', 'reason' => 'Prepare a company acquisition listing',
|
||||
'payload' => ['title' => 'Private company acquisition search', 'wizard_version' => '1', 'wizard_step' => '1'],
|
||||
])->assertCreated()->assertJsonPath('modality', 'company_purchase');
|
||||
$this->assertDatabaseHas('existing_businesses', ['owner_user_id' => $owner->id, 'modality' => 'company_purchase', 'status' => 'draft']);
|
||||
$this->get('/negocios?modality=company_purchase')->assertOk()
|
||||
->assertInertia(fn ($page) => $page->where('filters.modality', 'company_purchase')->has('results.data', 0));
|
||||
}
|
||||
|
||||
public function test_multiple_locations_require_distinct_public_paths_from_the_same_hierarchy(): void
|
||||
{
|
||||
config(['existing-business.enabled' => true]);
|
||||
|
||||
Reference in New Issue
Block a user