test('selecting a property field updates year built and total units field', function () {
ray($this->rfta->property->year_built)->label('rfta property - year_built');
$property = Property::factory()->create();
ray($property->year_built)->label('new property - year_built');
// Simulate selecting a property to see if other fields are updated
/** @phpstan-ignore-next-line */
livewire(RftaResource\Pages\EditRfta::class, ['record' => $this->rfta->id])
->set('property_id', $property->id)
->assertSet('year_built', $property->year_built)
->assertSet('total_units', $property->total_units);
});
test('selecting a property field updates year built and total units field', function () {
ray($this->rfta->property->year_built)->label('rfta property - year_built');
$property = Property::factory()->create();
ray($property->year_built)->label('new property - year_built');
// Simulate selecting a property to see if other fields are updated
/** @phpstan-ignore-next-line */
livewire(RftaResource\Pages\EditRfta::class, ['record' => $this->rfta->id])
->set('property_id', $property->id)
->assertSet('year_built', $property->year_built)
->assertSet('total_units', $property->total_units);
});