/home/alixis5/integrate.sellofinance.com/tests/Unit/Models
NameSizeModeActions
CustomerEmploymentTest.php19670644editdlrm
Edit: /home/alixis5/integrate.sellofinance.com/tests/Unit/Models/CustomerEmploymentTest.php (1967B)
'emp-001', 'createdAt' => '2026-04-09T10:00:00Z', 'modifiedAt' => '2026-04-09T10:00:00Z', 'customerProfileId' => 'prof-001', 'employmentType' => 'privateSector', 'employerName' => 'ADNOC', 'jobTitle' => 'Engineer', 'salaryTransfer' => true, 'employerCategory' => 'listed', 'workSinceDate' => '2018-01-01', 'employerCountry' => 'AE', 'employmentStatus' => 'active', ]; public function test_from_espo_maps_all_fields(): void { $model = CustomerEmployment::fromEspo($this->espoPayload); $this->assertSame('emp-001', $model->id); $this->assertSame('prof-001', $model->customerProfileId); $this->assertSame('privateSector', $model->employmentType); $this->assertSame('ADNOC', $model->employerName); $this->assertSame('Engineer', $model->jobTitle); $this->assertTrue($model->salaryTransfer); $this->assertSame('listed', $model->employerCategory); $this->assertSame('2018-01-01', $model->workSinceDate); $this->assertSame('AE', $model->employerCountry); $this->assertSame('active', $model->employmentStatus); } public function test_optional_fields_default_to_null(): void { $model = CustomerEmployment::fromEspo([ 'id' => 'emp-002', 'createdAt' => '', 'modifiedAt' => '', 'customerProfileId' => 'prof-001', ]); $this->assertNull($model->employmentType); $this->assertNull($model->employerName); $this->assertFalse($model->salaryTransfer); } }