Ejemplo n.º 1
0
 /**
  * @test
  */
 public function it_has_a_trim_scope()
 {
     factory(App\Models\WasteRegisterEntry::class)->create();
     sleep(1);
     factory(App\Models\WasteRegisterEntry::class)->create(['waste_codes_id' => factory(App\Models\WasteCode::class)->create(['description' => 'Slitting Trim Waste'])->id]);
     foreach (App\Models\WasteRegisterEntry::trim()->get() as $entry) {
         $this->assertEquals('Slitting Trim Waste', $entry->wasteCode->description);
     }
 }