<?php
use App\Models\{Invoice,Merchant};
it('never returns another merchants invoice through tenant scope',function(){ $a=Merchant::factory()->create();$b=Merchant::factory()->create();$invoice=Invoice::factory()->for($a)->create();expect(Invoice::forMerchant($b->id)->whereKey($invoice->id)->exists())->toBeFalse();});
