/** @test */ public function it_stores_related_model_in_relations_field() { $bom = Bom::includes('bar')->where('bar.id', '=', 1)->first(); $this->assertArrayNotHasKey('bar', $bom->attributesToArray()); $this->assertInstanceOf('Bar', $bom->getRelation('bar')); }