Changeset View
Changeset View
Standalone View
Standalone View
src/tests/Feature/PlanTest.php
Show First 20 Lines • Show All 100 Lines • ▼ Show 20 Lines | public function testCost(): void | ||||
$this->assertTrue( | $this->assertTrue( | ||||
$plan->cost() == 999, | $plan->cost() == 999, | ||||
"The total costs for this plan is not 9.99" | "The total costs for this plan is not 9.99" | ||||
); | ); | ||||
$this->assertTrue($plan->cost() == $package_costs); | $this->assertTrue($plan->cost() == $package_costs); | ||||
} | } | ||||
public function testTenant(): void | |||||
{ | |||||
$plan = Plan::where('title', 'individual')->first(); | |||||
$tenant = $plan->tenant()->first(); | |||||
$this->assertInstanceof(\App\Tenant::class, $tenant); | |||||
$this->assertSame(1, $tenant->id); | |||||
$tenant = $plan->tenant; | |||||
$this->assertInstanceof(\App\Tenant::class, $tenant); | |||||
$this->assertSame(1, $tenant->id); | |||||
} | |||||
} | } |